We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
stringify
undefined
1 parent 37e176d commit 2c38654Copy full SHA for 2c38654
lib/stringify.js
@@ -89,7 +89,7 @@ module.exports = function (object, opts) {
89
var objKeys;
90
var filter;
91
92
- if (options.encoder !== null && options.encoder !== undefined && typeof options.encoder !== 'function') {
+ if (options.encoder !== null && typeof options.encoder !== 'undefined' && typeof options.encoder !== 'function') {
93
throw new TypeError('Encoder has to be a function.');
94
}
95
0 commit comments