Move current version to global scope

This commit is contained in:
shinigami-eyes 2019-05-12 16:09:05 +02:00
parent c652fa5bce
commit 51c1c1ccf7

View File

@ -3,6 +3,8 @@ var browser = browser || chrome;
var PENDING_SUBMISSIONS = ':PENDING_SUBMISSIONS'
var MIGRATION = ':MIGRATION'
var CURRENT_VERSION = 11;
// If a user labels one of these URLs, they're making a mistake. Ignore the label.
// This list includes:
// * Social networks that are not supported
@ -239,7 +241,6 @@ browser.storage.local.get(['overrides', 'accepted', 'installationId'], v => {
overrides = v.overrides || {}
var migration = overrides[MIGRATION] || 0;
var CURRENT_VERSION = 11;
if(migration < CURRENT_VERSION){
for(var key of Object.getOwnPropertyNames(overrides)){