diff --git a/library/Director/Data/Db/DbObject.php b/library/Director/Data/Db/DbObject.php index 5ac6b155..e22b8ff0 100644 --- a/library/Director/Data/Db/DbObject.php +++ b/library/Director/Data/Db/DbObject.php @@ -385,7 +385,10 @@ abstract class DbObject return $this; } if ($key === 'id' || substr($key, -3) === '_id') { - if ((int) $value === (int) $this->properties[$key]) { + if ($value !== null + && $this->properties[$key] !== null + && (int) $value === (int) $this->properties[$key] + ) { return $this; } }