Skip to content

Commit 648b21b

Browse files
committed
fix: validate only known options
1 parent 0c25109 commit 648b21b

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lib/verify-config.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ const VALIDATORS = {
99
pkgRoot: isNonEmptyString,
1010
};
1111

12-
module.exports = options => {
13-
const errors = Object.entries(options).reduce(
12+
module.exports = ({npmPublish, tarballDir, pkgRoot}) => {
13+
const errors = Object.entries({npmPublish, tarballDir, pkgRoot}).reduce(
1414
(errors, [option, value]) =>
1515
!isUndefined(value) && value !== false && !VALIDATORS[option](value)
1616
? [...errors, getError(`EINVALID${option.toUpperCase()}`, {[option]: value})]

0 commit comments

Comments
 (0)