From 5ba6c901272c5ae1d5d013c9e958457b34d167a9 Mon Sep 17 00:00:00 2001 From: Nicolas Boisselier Date: Mon, 26 Aug 2024 23:09:47 +0200 Subject: [PATCH] fix bug when $_SERVER['REQUEST_METHOD'] is empty --- www/dbq/dbq.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/dbq/dbq.php b/www/dbq/dbq.php index 957c15b7..b10b76d7 100644 --- a/www/dbq/dbq.php +++ b/www/dbq/dbq.php @@ -483,8 +483,8 @@ class DbQ extends nb { if (!$keys) $keys = $all; $keys = array_keys($keys); - $values = ($_SERVER['REQUEST_METHOD'] == 'POST') ? $_POST : explode($this->param_args_sep,$this->params['args']); - if ($_SERVER['REQUEST_METHOD'] == 'POST') { + # NB 26.08.24 $values = ($_SERVER['REQUEST_METHOD'] == 'POST') ? $_POST : explode($this->param_args_sep,$this->params['args']); + if (!empty($_SERVER['REQUEST_METHOD']) and $_SERVER['REQUEST_METHOD'] == 'POST') { $values = $_POST; } elseif($this->params['args']) { $values = explode($this->param_args_sep,$this->params['args']); -- 2.47.3