diff options
Diffstat (limited to 'app/scripts/background.js')
-rw-r--r-- | app/scripts/background.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/app/scripts/background.js b/app/scripts/background.js index 2451cddb6..1479d9f72 100644 --- a/app/scripts/background.js +++ b/app/scripts/background.js @@ -26,6 +26,8 @@ const setupMetamaskMeshMetrics = require('./lib/setupMetamaskMeshMetrics') const EdgeEncryptor = require('./edge-encryptor') const getFirstPreferredLangCode = require('./lib/get-first-preferred-lang-code') const getObjStructure = require('./lib/getObjStructure') +const ipfsContent = require('./lib/ipfsContent.js') + const { ENVIRONMENT_TYPE_POPUP, ENVIRONMENT_TYPE_NOTIFICATION, @@ -66,6 +68,7 @@ initialize().catch(log.error) // setup metamask mesh testing container setupMetamaskMeshMetrics() + /** * An object representing a transaction, in whatever state it is in. * @typedef TransactionMeta @@ -155,6 +158,7 @@ async function initialize () { const initLangCode = await getFirstPreferredLangCode() await setupController(initState, initLangCode) log.debug('MetaMask initialization complete.') + ipfsContent(initState.NetworkController.provider) } // @@ -258,6 +262,7 @@ function setupController (initState, initLangCode) { }) global.metamaskController = controller + // report failed transactions to Sentry controller.txController.on(`tx:status-update`, (txId, status) => { if (status !== 'failed') return @@ -378,7 +383,7 @@ function setupController (initState, initLangCode) { } // communication with page or other extension - function connectExternal(remotePort) { + function connectExternal (remotePort) { const originDomain = urlUtil.parse(remotePort.sender.url).hostname const portStream = new PortStream(remotePort) controller.setupUntrustedCommunication(portStream, originDomain) |