aboutsummaryrefslogtreecommitdiffstats
path: root/app/scripts/controllers/preferences.js
diff options
context:
space:
mode:
Diffstat (limited to 'app/scripts/controllers/preferences.js')
-rw-r--r--app/scripts/controllers/preferences.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/app/scripts/controllers/preferences.js b/app/scripts/controllers/preferences.js
index 7212c7c43..aa8e05fcc 100644
--- a/app/scripts/controllers/preferences.js
+++ b/app/scripts/controllers/preferences.js
@@ -7,6 +7,7 @@ class PreferencesController {
constructor (opts = {}) {
const initState = extend({
frequentRpcList: [],
+ currentAccountTab: 'history',
}, opts.initState)
this.store = new ObservableStore(initState)
}
@@ -35,6 +36,13 @@ class PreferencesController {
})
}
+ setCurrentAccountTab (currentAccountTab) {
+ return new Promise((resolve, reject) => {
+ this.store.updateState({ currentAccountTab })
+ resolve()
+ })
+ }
+
addToFrequentRpcList (_url) {
const rpcList = this.getFrequentRpcList()
const index = rpcList.findIndex((element) => { return element === _url })