Synchronet now requires the libarchive development package (e.g. libarchive-dev on Debian-based Linux distros, libarchive.org for more info) to build successfully.

Commit 90412f51 authored by echicken's avatar echicken 🐔

Fix whoopsie in previous doopsie

parent 1adb2b36
......@@ -93,13 +93,13 @@ function registerEventListener(scope, callback, params) {
document.addEventListener('DOMContentLoaded', () => {
// originally based on dark-mode-switch by Christian Oliff
if ($('#darkSwitch').length) {
$('#darkSwitch').checked = localStorage.getItem('darkSwitch') || (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches);
$('#darkSwitch').prop('checked', localStorage.getItem('darkSwitch') || (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches));
$('#darkSwitch').change(resetTheme);
resetTheme();
function resetTheme() {
if (this.checked) {
if ($('#darkSwitch').prop('checked')) {
$('body').addClass('dark');
localStorage.setItem('darkSwitch', 'dark');
localStorage.setItem('darkSwitch', true);
} else {
$('body').removeClass('dark');
localStorage.removeItem('darkSwitch');
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment