Skip to content

Commit 35a298b

Browse files
committed
Merge pull request #473 from gabalafou/fix-debug-ie9
Fix broken logDebug() in IE9 and below
2 parents d105f37 + 36db1b7 commit 35a298b

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/raven.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1081,7 +1081,12 @@ Raven.prototype = {
10811081

10821082
_logDebug: function(level) {
10831083
if (this._originalConsoleMethods[level] && this.debug) {
1084-
this._originalConsoleMethods[level].apply(this._originalConsole, [].slice.call(arguments, 1));
1084+
// In IE<10 console methods do not have their own 'apply' method
1085+
Function.prototype.apply.call(
1086+
this._originalConsoleMethods[level],
1087+
this._originalConsole,
1088+
[].slice.call(arguments, 1)
1089+
);
10851090
}
10861091
},
10871092

0 commit comments

Comments
 (0)