Skip to content
Snippets Groups Projects
Commit b6e4775c authored by Jonas Leder's avatar Jonas Leder
Browse files

darkmode on logout

parent 79b41bd8
Branches
Tags
No related merge requests found
Pipeline #208 passed
......@@ -164,7 +164,7 @@ def authorizeGithub():
@app.route('/user/logout')
def logout():
resp = make_response('logout successful. Redirecting you back in 2 sec.\n<script> window.setTimeout(function(){\nwindow.location.href = "/";\n}, 2000);</script>')
resp = make_response('<style>\n@media (prefers-color-scheme: dark) {\nbody {\ncolor: #b3b3b3;\nbackground: #151d28;\n}\n}\n</style>\n<h2>Logout successful. Redirecting you back in 2 sec.</h2>\n<script> window.setTimeout(function(){\nwindow.location.href = "/";\n}, 2000);</script>')
resp.set_cookie('userID', "", max_age=0) #Set the max age of the cookies to 0, this means delete the cookies.
resp.set_cookie('username', "", max_age=0)
return resp
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment