From 659a115b3d4943863fedc55de3f5e77dcc840fc8 Mon Sep 17 00:00:00 2001 From: choelzl Date: Thu, 24 Feb 2022 02:33:27 +0100 Subject: [PATCH] WIP --- web/alert/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/alert/index.js b/web/alert/index.js index 483386e..7ff25ea 100644 --- a/web/alert/index.js +++ b/web/alert/index.js @@ -12,7 +12,7 @@ $(async function () { $(audio).on("loadedmetadata", function() { resolve(audio); }); - audio.volume = Math.max(1,Math.min(0,volume/100.0)); + audio.volume = Math.min(1,Math.max(0,volume/100.0)); audio.src = src; audio.play().catch((err)=>{ if(err.toString().startsWith('NotAllowedError')){