mirror of
https://github.com/FAUSheppy/tmnf-replay-server.git
synced 2025-12-06 07:01:37 +01:00
feat: user settings map filter & reload
This commit is contained in:
@@ -32,14 +32,16 @@ function submit(e){
|
||||
}
|
||||
|
||||
const s = e.target
|
||||
console.log(s)
|
||||
const json_data = JSON.stringify({ payload : [ { key : s.id, value : s.checked } ] })
|
||||
console.log(json_data)
|
||||
fetch("/update-user-settings", {
|
||||
method: "POST",
|
||||
credentials: "include",
|
||||
headers: {'Content-Type': 'application/json'},
|
||||
body: json_data
|
||||
}
|
||||
).then(response => {})
|
||||
).then(response => {
|
||||
if(s.id.startsWith("show")){
|
||||
window.location.reload()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user