Last active
June 28, 2016 07:58
-
-
Save andrewtamura/971416c485d0cd2311382c9c38571d3b to your computer and use it in GitHub Desktop.
Multiple code paths with culprit
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var raven = require('./raven'); | |
function foo() { | |
try { | |
thowsException(); | |
} catch (err) { | |
raven.captureException(err, { | |
culprit: 'Error from thowsException in foo' | |
}); | |
} | |
} | |
function bar() { | |
try { | |
thowsException(); | |
} catch (err) { | |
raven.captureException(err, { | |
culprit: 'Error from thowsException in bar' | |
}); | |
} | |
} | |
function thowsException() { | |
throw new Error('Generic Error'); | |
} | |
foo(); | |
bar(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment