mirror of
https://github.com/bitwarden/browser
synced 2025-12-13 14:53:33 +00:00
lint fixes
This commit is contained in:
@@ -11,7 +11,7 @@ export default class AppIdService {
|
|||||||
|
|
||||||
private static async makeAndGetAppId(key: string) {
|
private static async makeAndGetAppId(key: string) {
|
||||||
const existingId = await UtilsService.getObjFromStorage<string>(key);
|
const existingId = await UtilsService.getObjFromStorage<string>(key);
|
||||||
if(existingId != null) {
|
if (existingId != null) {
|
||||||
return existingId;
|
return existingId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -11,7 +11,9 @@ export default class UtilsService {
|
|||||||
// ref: http://stackoverflow.com/a/2117523/1090359
|
// ref: http://stackoverflow.com/a/2117523/1090359
|
||||||
static newGuid(): string {
|
static newGuid(): string {
|
||||||
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {
|
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {
|
||||||
|
// tslint:disable-next-line
|
||||||
const r = Math.random() * 16 | 0;
|
const r = Math.random() * 16 | 0;
|
||||||
|
// tslint:disable-next-line
|
||||||
const v = c === 'x' ? r : (r & 0x3 | 0x8);
|
const v = c === 'x' ? r : (r & 0x3 | 0x8);
|
||||||
return v.toString(16);
|
return v.toString(16);
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user