improve 'debug' parameter
instead of checking on '1' or 'true', check that it is there and not '0' and 'false'. this allows using simply https://foo:8007/?debug instead of https://foo:8007/?debug=1 Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
parent
573bcd9a92
commit
3f683799a8
@ -323,7 +323,7 @@ fn get_index(username: Option<String>, token: Option<String>, template: &Handleb
|
||||
|
||||
if let Some(query_str) = parts.uri.query() {
|
||||
for (k, v) in form_urlencoded::parse(query_str.as_bytes()).into_owned() {
|
||||
if k == "debug" && v == "1" || v == "true" {
|
||||
if k == "debug" && v != "0" && v != "false" {
|
||||
debug = true;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user