From e2e080c404b655d7d5d89ee071f410b071ed289d Mon Sep 17 00:00:00 2001 From: Clemens Schwaighofer Date: Thu, 1 Jun 2023 10:58:11 +0900 Subject: [PATCH] Bug fix for DB\IO --- www/lib/CoreLibs/DB/IO.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/lib/CoreLibs/DB/IO.php b/www/lib/CoreLibs/DB/IO.php index a3837104..39dd0d0a 100644 --- a/www/lib/CoreLibs/DB/IO.php +++ b/www/lib/CoreLibs/DB/IO.php @@ -382,7 +382,7 @@ class IO /** @var array */ private array $pk_name_table = []; /** @var string internal primary key name, for cross calls in async */ - private string $pk_name; + private string $pk_name = ''; /** @var bool if we use RETURNING in the INSERT call */ private bool $returning_id = false; /** @var string if a sync is running holds the hash key of the query */ @@ -1267,7 +1267,7 @@ class IO // ONLY insert with set pk name ($this->__checkQueryForInsert($this->query, true) && $this->pk_name != 'NULL') || // insert or update with returning add - ($this->__checkQueryForInsert($this->query) && $this->returning_id) + ($this->__checkQueryForInsert($this->query) && $this->returning_id) ) { $this->__dbSetInsertId( $this->returning_id,