From 985240294a201210b38221d6db8d4ddfb5608092 Mon Sep 17 00:00:00 2001 From: Brendan Early Date: Tue, 13 Aug 2024 23:35:10 -0500 Subject: [PATCH] fix default autolock value not being enforced --- src/background.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/background.ts b/src/background.ts index f84d78f9..bb59a2f9 100644 --- a/src/background.ts +++ b/src/background.ts @@ -535,6 +535,11 @@ async function setAutolock() { return; } + // Set default autolock value + if (UserSettings.items.autolock === undefined) { + UserSettings.items.autolock = 30; + } + if (Number(UserSettings.items.autolock) > 0) { chrome.alarms.create("autolock", { delayInMinutes: Number(UserSettings.items.autolock),