aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfrankiebee <frankie.diamond@gmail.com>2018-02-01 02:49:58 +0800
committerfrankiebee <frankie.diamond@gmail.com>2018-02-01 02:49:58 +0800
commitc3adbda5f561c20c011a7b78f1e84513cebba87e (patch)
tree5fee4830831858acb1ebbebbcbf5ea2262857a72
parente0caeae06ded5d0e7c74b5e174583fae378e7123 (diff)
downloadtangerine-wallet-browser-c3adbda5f561c20c011a7b78f1e84513cebba87e.tar
tangerine-wallet-browser-c3adbda5f561c20c011a7b78f1e84513cebba87e.tar.gz
tangerine-wallet-browser-c3adbda5f561c20c011a7b78f1e84513cebba87e.tar.bz2
tangerine-wallet-browser-c3adbda5f561c20c011a7b78f1e84513cebba87e.tar.lz
tangerine-wallet-browser-c3adbda5f561c20c011a7b78f1e84513cebba87e.tar.xz
tangerine-wallet-browser-c3adbda5f561c20c011a7b78f1e84513cebba87e.tar.zst
tangerine-wallet-browser-c3adbda5f561c20c011a7b78f1e84513cebba87e.zip
remove RecentBlocks from disk
-rw-r--r--app/scripts/metamask-controller.js4
-rw-r--r--app/scripts/migrations/021.js1
-rw-r--r--test/unit/migrations/021-test.js1
3 files changed, 3 insertions, 3 deletions
diff --git a/app/scripts/metamask-controller.js b/app/scripts/metamask-controller.js
index adc681f6f..15058188d 100644
--- a/app/scripts/metamask-controller.js
+++ b/app/scripts/metamask-controller.js
@@ -198,9 +198,7 @@ module.exports = class MetamaskController extends EventEmitter {
this.networkController.store.subscribe((state) => {
this.store.updateState({ NetworkController: state })
})
- this.recentBlocksController.store.subscribe((state) => {
- this.store.updateState({ RecentBlocks: state })
- })
+
this.infuraController.store.subscribe((state) => {
this.store.updateState({ InfuraController: state })
})
diff --git a/app/scripts/migrations/021.js b/app/scripts/migrations/021.js
index 0d3f35b77..d84e77b50 100644
--- a/app/scripts/migrations/021.js
+++ b/app/scripts/migrations/021.js
@@ -28,6 +28,7 @@ module.exports = {
function transformState (state) {
const newState = state
delete newState.BlacklistController
+ delete newState.RecentBlocks
return newState
}
diff --git a/test/unit/migrations/021-test.js b/test/unit/migrations/021-test.js
index 9d1066c13..458e9b4b5 100644
--- a/test/unit/migrations/021-test.js
+++ b/test/unit/migrations/021-test.js
@@ -9,6 +9,7 @@ describe('wallet2 is migrated successfully with out the BlacklistController', ()
.then((migratedData) => {
assert.equal(migratedData.meta.version, 21)
assert(!migratedData.data.BlacklistController)
+ assert(!migratedData.data.RecentBlocks)
done()
}).catch(done)
})