We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5fc4e8d commit af32c9bCopy full SHA for af32c9b
src/recognizer.js
@@ -40,10 +40,13 @@ var STATE_FAILED = 32;
40
* @param {Object} options
41
*/
42
function Recognizer(options) {
43
+ // make sure, options are copied over to a new object to prevent leaking it outside
44
+ options = extend({}, options || {});
45
+
46
this.id = uniqueId();
47
48
this.manager = null;
- this.options = merge(options || {}, this.defaults);
49
+ this.options = merge(options, this.defaults);
50
51
// default is enable true
52
this.options.enable = ifUndefined(this.options.enable, true);
0 commit comments