Revert "Switch tracking key to accountStorage" This reverts commit 549fae4015c049f2d194daa7176f5df1b67422ea.
| @@ -1,6 +1,5 @@ | ||
| 1 | 1 | import { registerDebugFunction } from './power-user.js'; |
| 2 | 2 | import { updateSecretDisplay } from './secrets.js'; |
| 3 | -import { accountStorage } from './util/AccountStorage.js'; | |
| 4 | 3 | |
| 5 | 4 | const storageKey = 'language'; |
| 6 | 5 | const overrideLanguage = localStorage.getItem(storageKey); |
| @@ -292,7 +291,7 @@ export async function initLocales() { | ||
| 292 | 291 | attributeFilter: ['data-i18n'], |
| 293 | 292 | }); |
| 294 | 293 | |
| 295 | 294 | if (accountStoragelocalStorage.getItem('trackDynamicTranslate') === 'true' && isSupportedNonEnglish()) { |
| 296 | 295 | trackMissingDynamicTranslate = new Set(); |
| 297 | 296 | } |
| 298 | 297 | |
| @@ -305,8 +304,8 @@ export async function initLocales() { | ||
| 305 | 304 | 'This includes things translated via the t`...` function and translate(). It will only track strings translated <b>after</b> this is toggled on, ' |
| 306 | 305 | + 'and when they actually pop up, so refreshing the page and opening popups, etc, is needed. Will only track if the current locale is not English.', |
| 307 | 306 | () => { |
| 308 | 307 | const isTracking = accountStoragelocalStorage.getItem('trackDynamicTranslate') !== 'true'; |
| 309 | 308 | accountStoragelocalStorage.setItem('trackDynamicTranslate', isTracking ? 'true' : 'false'); |
| 310 | 309 | if (isTracking && isSupportedNonEnglish()) { |
| 311 | 310 | trackMissingDynamicTranslate = new Set(); |
| 312 | 311 | toastr.success('Dynamic translation tracking enabled.'); |