Skip to content

Commit

Permalink
optimize:do unnecessary processing when changing options to null (req…
Browse files Browse the repository at this point in the history
  • Loading branch information
rickyes authored and reconbot committed Dec 13, 2018
1 parent e81c9b1 commit be7882b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ function initParams (uri, options, callback) {
}

var params = {}
if (typeof options === 'object') {
if (options !== null && typeof options === 'object') {
extend(params, options, {uri: uri})
} else if (typeof uri === 'string') {
extend(params, {uri: uri})
Expand Down

0 comments on commit be7882b

Please sign in to comment.