mirror of
https://github.com/rystaf/mlmym.git
synced 2024-11-05 06:43:21 +00:00
fix darkmode toggle
This commit is contained in:
parent
dd03bad6b2
commit
8a5b2094b7
|
@ -770,6 +770,9 @@ func Settings(w http.ResponseWriter, r *http.Request, ps httprouter.Params) {
|
||||||
} else if r.FormValue("darkmode") != "" {
|
} else if r.FormValue("darkmode") != "" {
|
||||||
setCookie(w, "", "Dark", "1")
|
setCookie(w, "", "Dark", "1")
|
||||||
*state.Dark = true
|
*state.Dark = true
|
||||||
|
} else {
|
||||||
|
setCookie(w, "", "Dark", "0")
|
||||||
|
*state.Dark = false
|
||||||
}
|
}
|
||||||
if r.FormValue("shownsfw") != "" {
|
if r.FormValue("shownsfw") != "" {
|
||||||
setCookie(w, "", "ShowNSFW", "1")
|
setCookie(w, "", "ShowNSFW", "1")
|
||||||
|
|
Loading…
Reference in a new issue