Make sync update backwards compatible

This commit is contained in:
Mariam Maarouf 2019-10-20 13:41:12 +02:00
parent 3526b390d5
commit 7fe653eae3
2 changed files with 14 additions and 11 deletions

View File

@ -9,7 +9,11 @@ chrome.runtime.onMessage.addListener((message, sender, sendResponse) => {
});
const replaceAll = () => {
chrome.storage.sync.get(null, items => {
chrome.storage.sync.get(null, replaceAllInStorage)
chrome.storage.local.get(null, replaceAllInStorage)
}
const replaceAllInStorage = (items) => {
if (!items[DEACTIVATE_KEY]) {
for (var key in items) {
if (key == 'person') {
@ -20,7 +24,6 @@ const replaceAll = () => {
}
}
}
})
}
const escapeAndReplace = (input_word, replace_value, case_sensitive) => {

View File

@ -3,7 +3,7 @@
"manifest_version": 2,
"name": "InteractiveFics",
"author": "mariamrf",
"version": "5.0.1",
"version": "5.0.2",
"description": "Replaces Y/N & other variables in Reader Insert/second person fics with words of your choice.",
"browser_action": {
"default_title": "InteractiveFics",