From 433787ec99ee8c3f796ed6abcf516cfe84c5e0e3 Mon Sep 17 00:00:00 2001 From: PatrikB Date: Tue, 18 Jun 2024 15:10:28 +0200 Subject: [PATCH] Expermineting to drag results --- api/ui/results.php | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/api/ui/results.php b/api/ui/results.php index ff7f3f511c..7698ba915c 100644 --- a/api/ui/results.php +++ b/api/ui/results.php @@ -100,12 +100,14 @@ public function get() { if($e == $id) { echo "found in e.\n"; } - foreach ($e as $ok) { - if (gettype($ok) == 'string') { - echo $ok; - } - if($ok == $id) { - echo "found in e.\n"; + if (gettype($e)=='array') { + foreach ($e as $ok) { + if (gettype($ok) == 'string') { + echo $ok; + } + if ($ok == $id) { + echo "found in e.\n"; + } } } }