Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Commit

Permalink
add node env to crash reports
Browse files Browse the repository at this point in the history
allow system crash reporter to run
run crash reporter for renderer on macos (this is only required for macos)
auditors: @bbondy @aekeus
  • Loading branch information
bridiver committed Oct 6, 2016
1 parent 2b8fb19 commit 3f3e69a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/crash-herald.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@ exports.init = () => {
companyName: 'Brave.com',
submitURL: appConfig.crashes.crashSubmitUrl,
autoSubmit: true,
ignoreSystemCrashHandler: true
extra: {
node_env: process.env.NODE_ENV
}
}
crashReporter.start(options)
}
7 changes: 7 additions & 0 deletions js/entry.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,13 @@ require('../less/notificationBar.less')
require('../less/addEditBookmark.less')
require('../node_modules/font-awesome/css/font-awesome.css')

if (process.platform === 'darwin') {
// Setup the crash handling for mac renderer processes
// https://github.com/electron/electron/blob/master/docs/api/crash-reporter.md#crashreporterstartoptions
const CrashHerald = require('../app/crash-herald')
CrashHerald.init()
}

const React = require('react')
const ReactDOM = require('react-dom')
const Window = require('./components/window')
Expand Down

1 comment on commit 3f3e69a

@bbondy
Copy link
Member

@bbondy bbondy commented on 3f3e69a Oct 12, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

++

Please sign in to comment.