From 2e2918802082b80e8606bea80aa194458d25d2f1 Mon Sep 17 00:00:00 2001 From: Thomas Gelf Date: Fri, 20 Sep 2019 03:39:12 +0200 Subject: [PATCH] DbObject: logId should show autoinc id in case... ...nothing else is present --- library/Director/Data/Db/DbObject.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/library/Director/Data/Db/DbObject.php b/library/Director/Data/Db/DbObject.php index 0d29cf77..9b21168d 100644 --- a/library/Director/Data/Db/DbObject.php +++ b/library/Director/Data/Db/DbObject.php @@ -988,6 +988,10 @@ abstract class DbObject $logId = $id; } + if ($logId === null && $this->autoincKeyName) { + $logId = $this->getAutoincId(); + } + return $logId; }