From 217784bbff282d913d1773a1633a3c15b14657c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pauli=20J=C3=A4rvinen?= Date: Sat, 15 Aug 2026 17:30:56 +0300 Subject: [PATCH] fix(dbal): Regression on PreparedStatement caused by fcc63b9603596c1b MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This small change included in https://github.com/nextcloud/server/pull/58891 broke PreparedStatement::bindValue and PreparedStatement::bindParam. The empty array has different meaning on $params than the null value, purging all the parameters previously passed to Statement. The problem commit is included in v35.0.0beta1 and v35.0.0beta2 but not in any v34 versions. Signed-off-by: Pauli Järvinen --- lib/private/DB/PreparedStatement.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/private/DB/PreparedStatement.php b/lib/private/DB/PreparedStatement.php index a76fbea4b4bc7..c0af67453cc37 100644 --- a/lib/private/DB/PreparedStatement.php +++ b/lib/private/DB/PreparedStatement.php @@ -85,7 +85,7 @@ public function bindParam($param, &$variable, $type = ParameterType::STRING, $le #[\Override] public function execute($params = null): IResult { - return ($this->result = new ResultAdapter($this->statement->execute($params ?? []))); + return ($this->result = new ResultAdapter($this->statement->execute($params))); } #[\Override]