aboutsummaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorDan Finlay <dan@danfinlay.com>2016-07-01 09:22:16 +0800
committerDan Finlay <dan@danfinlay.com>2016-07-01 09:22:16 +0800
commite55938ed15428b452224f2d731c1e7ad141869d4 (patch)
tree7f267bf875e1bd714896cde8ae7244c601eb5d4a /app
parent9a8ede22106c3f59d014be4905a078711180d30c (diff)
downloadtangerine-wallet-browser-e55938ed15428b452224f2d731c1e7ad141869d4.tar
tangerine-wallet-browser-e55938ed15428b452224f2d731c1e7ad141869d4.tar.gz
tangerine-wallet-browser-e55938ed15428b452224f2d731c1e7ad141869d4.tar.bz2
tangerine-wallet-browser-e55938ed15428b452224f2d731c1e7ad141869d4.tar.lz
tangerine-wallet-browser-e55938ed15428b452224f2d731c1e7ad141869d4.tar.xz
tangerine-wallet-browser-e55938ed15428b452224f2d731c1e7ad141869d4.tar.zst
tangerine-wallet-browser-e55938ed15428b452224f2d731c1e7ad141869d4.zip
First simple version of ui mocker
Diffstat (limited to 'app')
-rw-r--r--app/scripts/popup.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/app/scripts/popup.js b/app/scripts/popup.js
index 5c5cf0455..2e5b98896 100644
--- a/app/scripts/popup.js
+++ b/app/scripts/popup.js
@@ -54,12 +54,14 @@ function setupControllerConnection (stream, cb) {
}
function getCurrentDomain (cb) {
+ const unknown = '<unknown>'
+ if (!chrome.tabs) return cb(null, unknown)
chrome.tabs.query({active: true, currentWindow: true}, function (results) {
var activeTab = results[0]
var currentUrl = activeTab && activeTab.url
var currentDomain = url.parse(currentUrl).host
if (!currentUrl) {
- return cb(null, '<unknown>')
+ return cb(null, unknown)
}
cb(null, currentDomain)
})
@@ -78,7 +80,7 @@ function setupApp (err, opts) {
alert(err.stack)
throw err
}
-
+
clearNotifications()
var container = document.getElementById('app-content')