Skip to content
This repository has been archived by the owner on Mar 10, 2020. It is now read-only.

Commit

Permalink
fix: config.set rejects buffer values
Browse files Browse the repository at this point in the history
License: MIT
Signed-off-by: Travis Person <[email protected]>
  • Loading branch information
Travis Person committed Jul 17, 2018
1 parent 7b33529 commit 2d5281d
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/config/set.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@ module.exports = (send) => {
return callback(new Error('Invalid key type'))
}

if (typeof value !== 'object' &&
typeof value !== 'boolean' &&
typeof value !== 'string') {
if (value === undefined || Buffer.isBuffer(value)) {
return callback(new Error('Invalid value type'))
}

Expand Down

0 comments on commit 2d5281d

Please sign in to comment.