Skip to content

Commit 358e3de

Browse files
authoredFeb 10, 2017
Update bindings.js
1 parent d4bd554 commit 358e3de

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed
 

‎bindings.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,9 @@ function bindings (opts) {
4848
} else if (!opts) {
4949
opts = {}
5050
}
51-
opts = Object.assign({}, defaults, opts);
51+
52+
// maps `defaults` onto `opts` object
53+
Object.keys(defaults).map(i => i in opts || (opts[i] = defaults[i]));
5254

5355
// Get the module root
5456
if (!opts.module_root) {

0 commit comments

Comments
 (0)
Please sign in to comment.