Ensure leading and trailing debounce options are coerced to booleans.

This commit is contained in:
jdalton
2015-06-21 17:29:16 -07:00
parent 134bf61205
commit 71ed48bb76

View File

@@ -7803,9 +7803,9 @@
var leading = true;
trailing = false;
} else if (isObject(options)) {
leading = options.leading;
leading = !!options.leading;
maxWait = 'maxWait' in options && nativeMax(+options.maxWait || 0, wait);
trailing = 'trailing' in options ? options.trailing : trailing;
trailing = 'trailing' in options ? !!options.trailing : trailing;
}
function cancel() {