Skip to content

Commit 5949ce9

Browse files
committed
Only ignore messages that don't have a type or message
Underscore.js throws a plain TypeError with no arguments. ugh.
1 parent 7fe0d9e commit 5949ce9

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/raven.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -507,7 +507,7 @@ function processException(type, message, fileurl, lineno, frames, options) {
507507
// This can only mean that the message was falsey since this value
508508
// is hardcoded into Sentry itself.
509509
// At this point, if the message is falsey, we bail since it's useless
510-
if (!message) return;
510+
if (!type && !message) return;
511511

512512
if (globalOptions.ignoreErrors.test(message)) return;
513513

test/raven.test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -609,7 +609,7 @@ describe('globals', function() {
609609
it('should ignored falsey messages', function() {
610610
this.sinon.stub(window, 'send');
611611

612-
processException('Error', '', 'http://example.com', []);
612+
processException('', '', 'http://example.com', []);
613613
assert.isFalse(window.send.called);
614614
});
615615
});

0 commit comments

Comments
 (0)