From 65e41e575de29f6fa19a09e86f40d48011e78f6f Mon Sep 17 00:00:00 2001 From: Tamius Han Date: Mon, 3 Jun 2019 00:37:19 +0200 Subject: [PATCH] Force override existing settings for 4.0 --- src/ext/lib/Settings.js | 18 ++++++++++-------- src/manifest.json | 2 +- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/src/ext/lib/Settings.js b/src/ext/lib/Settings.js index 9bbc95a..ddaee3d 100644 --- a/src/ext/lib/Settings.js +++ b/src/ext/lib/Settings.js @@ -6,6 +6,8 @@ import ObjectCopy from '../lib/ObjectCopy'; import Stretch from '../../common/enums/stretch.enum'; import VideoAlignment from '../../common/enums/video-alignment.enum'; + + class Settings { constructor(activeSettings, updateCallback) { @@ -103,16 +105,16 @@ class Settings { // if extension has been updated, update existing settings with any options added in the // new version. In addition to that, we remove old keys that are no longer used. - const patched = ObjectCopy.addNew(settings, this.default); - if(Debug.debug) { - console.log("[Settings.init] Results from ObjectCopy.addNew()?", patched, "\n\nSettings from storage", settings, "\ndefault?", this.default,); - } + // const patched = ObjectCopy.addNew(settings, this.default); + // if(Debug.debug) { + // console.log("[Settings.init] Results from ObjectCopy.addNew()?", patched, "\n\nSettings from storage", settings, "\ndefault?", this.default,); + // } - if(patched){ - this.active = patched; - } else { + // if(patched){ + // this.active = patched; + // } else { this.active = JSON.parse(JSON.stringify(this.default)); - } + // } this.set(this.active); return this.active; diff --git a/src/manifest.json b/src/manifest.json index bb2aba7..6b0b06a 100644 --- a/src/manifest.json +++ b/src/manifest.json @@ -2,7 +2,7 @@ "manifest_version": 2, "name": "Ultrawidify", "description": "Aspect ratio fixer for youtube that works around some people's disability to properly encode 21:9 (and sometimes, 16:9) videos.", - "version": "4.0.0a2", + "version": "4.0.0", "applications": { "gecko": { "id": "{cf02b1a7-a01a-4e37-a609-516a283f1ed3}"