summaryrefslogtreecommitdiffstats
path: root/layouts/partials/scripts-front.html
diff options
context:
space:
mode:
Diffstat (limited to 'layouts/partials/scripts-front.html')
-rw-r--r--layouts/partials/scripts-front.html6
1 files changed, 2 insertions, 4 deletions
diff --git a/layouts/partials/scripts-front.html b/layouts/partials/scripts-front.html
index 59c3bb0..9425769 100644
--- a/layouts/partials/scripts-front.html
+++ b/layouts/partials/scripts-front.html
@@ -1,6 +1,6 @@
<script data-cfasync="false">
// detect theme data in localStorage
- // change the data-theme attribute of body
+ // if diff change the data-theme attribute of body
var fujiThemeData = localStorage.getItem('fuji_theme');
if (fujiThemeData) {
if ($('body').attr('data-theme') !== fujiThemeData) {
@@ -12,12 +12,10 @@
}
});
}
- } else {
- localStorage.setItem('fuji_theme', $('body').attr('data-theme'));
}
</script>
<script data-cfasync="false">
- // ie
+ // ie detection
var ua = window.navigator.userAgent;
function browserDetection() {