aboutsummaryrefslogtreecommitdiff
path: root/web
diff options
context:
space:
mode:
authorGravatar Thomas Petazzoni <thomas.petazzoni@bootlin.com>2020-07-04 21:43:41 +0200
committerGravatar Thomas Petazzoni <thomas.petazzoni@bootlin.com>2020-07-04 21:43:41 +0200
commit6cfa5ff72b4a77ce8fc9d487efbc5436a691bdcc (patch)
treec6ca98f8f9d46d8d69cb3a8424458c5a360994bf /web
parent05ca3bedde25e5264c1e174f1a18713ad8c7c782 (diff)
downloadbuildroot-test-6cfa5ff72b4a77ce8fc9d487efbc5436a691bdcc.tar.gz
buildroot-test-6cfa5ff72b4a77ce8fc9d487efbc5436a691bdcc.tar.bz2
web/funcs.inc.php: access filters['symbols'] after checking it exists
This avoids a warning with PHP 7.4. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Diffstat (limited to 'web')
-rw-r--r--web/funcs.inc.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/web/funcs.inc.php b/web/funcs.inc.php
index b589e9d..c56fafa 100644
--- a/web/funcs.inc.php
+++ b/web/funcs.inc.php
@@ -58,8 +58,12 @@ function bab_format_sql_filter($db, $filters)
);
# Move the symbols away from filters since implode wouldn't work with an empty key
- $symbols = $filters['symbols'];
- unset($filters['symbols']);
+ if (array_key_exists("symbols", $filters)) {
+ $symbols = $filters['symbols'];
+ unset($filters['symbols']);
+ } else {
+ $symbols = false;
+ }
$sql_filters = implode(' and ', array_map(
function ($v, $k) use ($db, $status_map) {