DbObject: use original UUID in where

This allows to change a UUID
This commit is contained in:
Thomas Gelf 2023-03-07 18:22:59 +01:00
parent 045f4ec941
commit 6c611a5db4

View File

@ -1049,7 +1049,7 @@ abstract class DbObject
if ($this->hasUuidColumn() && $this->properties[$this->uuidColumn] !== null) {
return $this->db->quoteInto(
sprintf('%s = ?', $this->getUuidColumn()),
$this->connection->quoteBinary($this->getUniqueId()->getBytes())
$this->connection->quoteBinary($this->getOriginalProperty($this->uuidColumn))
);
}
if ($id = $this->getAutoincId()) {