From ef286f5ae30bc68988bfe01e27a8b88295c0348a Mon Sep 17 00:00:00 2001 From: filesite Date: Sun, 7 Jul 2024 08:32:55 +0800 Subject: [PATCH] bug fix: wrong value when no data in local storage --- www/js/beauty.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/js/beauty.js b/www/js/beauty.js index 0b4bb2f..c0c288c 100644 --- a/www/js/beauty.js +++ b/www/js/beauty.js @@ -104,7 +104,7 @@ if ($('#image_site').get(0)) { toggleLampshow(lanpnum); } $('#image_site .lampJS').click(function () { - lanpnum = lanpnum == 0 ? 1 : 0; + lanpnum = !lanpnum ? 1 : 0; toggleLampshow(lanpnum); saveLanpnumToLocalstorage(lanpnum); });