fix(sentry): No longer flood sentry with errors sent while running with --dev

This commit is contained in:
Ben Gotow 2015-03-10 10:42:03 -07:00
parent 16cd75a933
commit e42c649e54

View file

@ -21,6 +21,7 @@ module.exports = ErrorReporter = (function() {
// or renderer process // or renderer process
if (process.type === 'renderer') { if (process.type === 'renderer') {
this.spec = atom.inSpecMode(); this.spec = atom.inSpecMode();
this.dev = atom.inDevMode();
atom.onDidThrowError(function(_arg) { atom.onDidThrowError(function(_arg) {
return self.reportError(_arg.originalError, { return self.reportError(_arg.originalError, {
@ -57,7 +58,9 @@ module.exports = ErrorReporter = (function() {
if (this.spec) { if (this.spec) {
return; return;
} }
if (this.dev) {
return;
}
return this.client.captureError(err, { return this.client.captureError(err, {
extra: metadata, extra: metadata,
tags: { tags: {