mirror of
https://github.com/bitwarden/browser.git
synced 2024-09-19 02:51:14 +02:00
installedVersionKey constant
This commit is contained in:
parent
7724fe6815
commit
e0f90849fc
@ -263,8 +263,7 @@ export default class RuntimeBackground {
|
|||||||
|
|
||||||
private async checkOnInstalled() {
|
private async checkOnInstalled() {
|
||||||
if (this.isSafari) {
|
if (this.isSafari) {
|
||||||
const installedVersionKey = 'installedVersion';
|
const installedVersion = await this.storageService.get<string>(ConstantsService.installedVersionKey);
|
||||||
const installedVersion = await this.storageService.get<string>(installedVersionKey);
|
|
||||||
if (installedVersion == null) {
|
if (installedVersion == null) {
|
||||||
this.onInstalledReason = 'install';
|
this.onInstalledReason = 'install';
|
||||||
} else if (BrowserApi.getApplicationVersion() !== installedVersion) {
|
} else if (BrowserApi.getApplicationVersion() !== installedVersion) {
|
||||||
@ -272,7 +271,8 @@ export default class RuntimeBackground {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (this.onInstalledReason != null) {
|
if (this.onInstalledReason != null) {
|
||||||
await this.storageService.save(installedVersionKey, BrowserApi.getApplicationVersion());
|
await this.storageService.save(ConstantsService.installedVersionKey,
|
||||||
|
BrowserApi.getApplicationVersion());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user