diff options
author | kumavis <kumavis@users.noreply.github.com> | 2018-10-30 09:57:51 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-30 09:57:51 +0800 |
commit | 73eeeda2157e8a7ef61ff1f1fd0f4b94821f2e6f (patch) | |
tree | 51b163f772d253b8e56588fd254ca918a8b058a2 /app/scripts/background.js | |
parent | 310229d22e5e916e8d6e3b1a469b9b196e0f70c2 (diff) | |
parent | 7ae5a23b6c0e9839f63bba52ab5bf7da00bef173 (diff) | |
download | tangerine-wallet-browser-73eeeda2157e8a7ef61ff1f1fd0f4b94821f2e6f.tar tangerine-wallet-browser-73eeeda2157e8a7ef61ff1f1fd0f4b94821f2e6f.tar.gz tangerine-wallet-browser-73eeeda2157e8a7ef61ff1f1fd0f4b94821f2e6f.tar.bz2 tangerine-wallet-browser-73eeeda2157e8a7ef61ff1f1fd0f4b94821f2e6f.tar.lz tangerine-wallet-browser-73eeeda2157e8a7ef61ff1f1fd0f4b94821f2e6f.tar.xz tangerine-wallet-browser-73eeeda2157e8a7ef61ff1f1fd0f4b94821f2e6f.tar.zst tangerine-wallet-browser-73eeeda2157e8a7ef61ff1f1fd0f4b94821f2e6f.zip |
Merge pull request #5560 from MetaMask/sentry-enhancements2
Sentry - various enhancements to help debugging (alternate)
Diffstat (limited to 'app/scripts/background.js')
-rw-r--r-- | app/scripts/background.js | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/app/scripts/background.js b/app/scripts/background.js index 6b3ac2664..2a3c5b08b 100644 --- a/app/scripts/background.js +++ b/app/scripts/background.js @@ -23,7 +23,7 @@ const createStreamSink = require('./lib/createStreamSink') const NotificationManager = require('./lib/notification-manager.js') const MetamaskController = require('./metamask-controller') const rawFirstTimeState = require('./first-time-state') -const setupRaven = require('./lib/setupRaven') +const setupSentry = require('./lib/setupSentry') const reportFailedTxToSentry = require('./lib/reportFailedTxToSentry') const setupMetamaskMeshMetrics = require('./lib/setupMetamaskMeshMetrics') const EdgeEncryptor = require('./edge-encryptor') @@ -50,7 +50,7 @@ global.METAMASK_NOTIFIER = notificationManager // setup sentry error reporting const release = platform.getVersion() -const raven = setupRaven({ release }) +const sentry = setupSentry({ release }) // browser check if it is Edge - https://stackoverflow.com/questions/9847580/how-to-detect-safari-chrome-ie-firefox-and-opera-browser // Internet Explorer 6-11 @@ -195,14 +195,14 @@ async function loadStateFromPersistence () { // we were able to recover (though it might be old) versionedData = diskStoreState const vaultStructure = getObjStructure(versionedData) - raven.captureMessage('MetaMask - Empty vault found - recovered from diskStore', { + sentry.captureMessage('MetaMask - Empty vault found - recovered from diskStore', { // "extra" key is required by Sentry extra: { vaultStructure }, }) } else { // unable to recover, clear state versionedData = migrator.generateInitialState(firstTimeState) - raven.captureMessage('MetaMask - Empty vault found - unable to recover') + sentry.captureMessage('MetaMask - Empty vault found - unable to recover') } } @@ -210,7 +210,7 @@ async function loadStateFromPersistence () { migrator.on('error', (err) => { // get vault structure without secrets const vaultStructure = getObjStructure(versionedData) - raven.captureException(err, { + sentry.captureException(err, { // "extra" key is required by Sentry extra: { vaultStructure }, }) @@ -275,7 +275,7 @@ function setupController (initState, initLangCode) { if (status !== 'failed') return const txMeta = controller.txController.txStateManager.getTx(txId) try { - reportFailedTxToSentry({ raven, txMeta }) + reportFailedTxToSentry({ sentry, txMeta }) } catch (e) { console.error(e) } |