summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Rettberg2020-06-18 17:35:27 +0200
committerSimon Rettberg2020-07-30 13:26:32 +0200
commit7d44e6438bbfafacde5a19c2888afec8bd9537b5 (patch)
treedede2410ac2e71ef0a522a04121719cad7a4caee
parent[locations] Show colored bars for used/idle/offline in overview (diff)
downloadslx-admin-7d44e6438bbfafacde5a19c2888afec8bd9537b5.tar.gz
slx-admin-7d44e6438bbfafacde5a19c2888afec8bd9537b5.tar.xz
slx-admin-7d44e6438bbfafacde5a19c2888afec8bd9537b5.zip
[inc/Request] Don't treat 0 as empty
-rw-r--r--inc/request.inc.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/inc/request.inc.php b/inc/request.inc.php
index 6104fafd..7e9ed97e 100644
--- a/inc/request.inc.php
+++ b/inc/request.inc.php
@@ -75,7 +75,7 @@ class Request
}
return $default;
}
- if ($default === self::REQUIRED && empty($array[$key])) {
+ if ($default === self::REQUIRED && (string)$array[$key] === '') {
Message::addError('main.parameter-empty', $key);
Util::redirect('?do=' . $_REQUEST['do']);
}