1
0
mirror of https://github.com/bitwarden/web synced 2026-01-02 08:33:18 +00:00

allow users to change lock options, default to 15 min

This commit is contained in:
Kyle Spearrin
2018-07-27 15:08:59 -04:00
parent 4b4e847816
commit f385c3773c
6 changed files with 63 additions and 2 deletions

View File

@@ -7,6 +7,13 @@ export class HtmlStorageService implements StorageService {
ConstantsService.localeKey, ConstantsService.lockOptionKey]);
private localStorageStartsWithKeys = ['twoFactorToken_'];
async init() {
const lockOption = await this.get<number>(ConstantsService.lockOptionKey);
if (lockOption == null) {
await this.save(ConstantsService.lockOptionKey, 15);
}
}
get<T>(key: string): Promise<T> {
let json: string = null;
if (this.isLocalStorage(key)) {

View File

@@ -94,7 +94,7 @@ export class WebPlatformUtilsService implements PlatformUtilsService {
}
lockTimeout(): number {
return 15;
return null;
}
launchUri(uri: string, options?: any): void {