diff --git a/lib/Table.php b/lib/Table.php index 9da91a5a..f7bbeaaf 100644 --- a/lib/Table.php +++ b/lib/Table.php @@ -518,7 +518,8 @@ private function set_table_name(): void $this->table = $parts[count($parts) - 1]; } - if (($db = $this->class->getStaticPropertyValue('db', null)) || ($db = $this->class->getStaticPropertyValue('db_name', null))) { + $db = $this->class->getStaticPropertyValue('db', null) ?? $this->class->getStaticPropertyValue('db_name', null); + if ($db) { $this->db_name = $db; } }