aboutsummaryrefslogtreecommitdiffstats
path: root/app/scripts/inpage.js
diff options
context:
space:
mode:
authorChen Wei <chenwei@byzantine-lab.io>2019-07-18 14:14:50 +0800
committerChen Wei <chenwei@byzantine-lab.io>2019-07-18 14:14:50 +0800
commit72099b5836825e4423a52734e521663ba939238f (patch)
treedfc9e266c4ccb5d361ab4c8ce3f606432dc5bb9f /app/scripts/inpage.js
parent107553f77c32b89792d42ab7d174eade56d1b63c (diff)
downloadtangerine-wallet-browser-72099b5836825e4423a52734e521663ba939238f.tar.gz
tangerine-wallet-browser-72099b5836825e4423a52734e521663ba939238f.tar.zst
tangerine-wallet-browser-72099b5836825e4423a52734e521663ba939238f.zip
1. rename stream target name 2. do not expose web3
Diffstat (limited to 'app/scripts/inpage.js')
-rw-r--r--app/scripts/inpage.js18
1 files changed, 9 insertions, 9 deletions
diff --git a/app/scripts/inpage.js b/app/scripts/inpage.js
index 4ab361469..705741cf1 100644
--- a/app/scripts/inpage.js
+++ b/app/scripts/inpage.js
@@ -19,8 +19,8 @@ log.setDefaultLevel(process.env.METAMASK_DEBUG ? 'debug' : 'warn')
// setup background connection
const metamaskStream = new LocalMessageDuplexStream({
- name: 'inpage',
- target: 'contentscript',
+ name: 'inpage_tangerine',
+ target: 'contentscript_tangerine',
})
// compose the inpage provider
@@ -115,13 +115,13 @@ window.tangerine = createStandardProvider(proxiedInpageProvider)
// setup web3
//
-if (typeof window.web3 !== 'undefined') {
- throw new Error(`MetaMask detected another web3.
- MetaMask will not work reliably with another web3 extension.
- This usually happens if you have two MetaMasks installed,
- or MetaMask and another web3 extension. Please remove one
- and try again.`)
-}
+// if (typeof window.web3 !== 'undefined') {
+// throw new Error(`MetaMask detected another web3.
+// MetaMask will not work reliably with another web3 extension.
+// This usually happens if you have two MetaMasks installed,
+// or MetaMask and another web3 extension. Please remove one
+// and try again.`)
+// }
const web3 = new Web3(proxiedInpageProvider)
web3.setProvider = function () {