This commit is contained in:
Chromatic
2026-04-21 15:42:56 +00:00
parent 5c6ec06f45
commit 4a6485da4e
58 changed files with 5359 additions and 24 deletions
+11
View File
@@ -0,0 +1,11 @@
const Range = require('../classes/range')
const validRange = (range, options) => {
try {
// Return '*' instead of '' so that truthiness works.
// This will throw if it's invalid anyway
return new Range(range, options).range || '*'
} catch (er) {
return null
}
}
module.exports = validRange