Skip to content

Commit bf7ed38

Browse files
committed
Merge pull request #447 from jimf/fix-this-ref
Fix `this` reference
1 parent d02b693 commit bf7ed38

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/raven.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -499,10 +499,11 @@ Raven.prototype = {
499499

500500
/**** Private functions ****/
501501
_ignoreNextOnError: function () {
502+
var self = this;
502503
this._ignoreOnError += 1;
503504
setTimeout(function () {
504505
// onerror should trigger before setTimeout
505-
this._ignoreOnError -= 1;
506+
self._ignoreOnError -= 1;
506507
});
507508
},
508509

0 commit comments

Comments
 (0)