From: Alan Knowles Date: Wed, 14 Oct 2015 07:48:59 +0000 (+0800) Subject: DataObjects/Core_notify.php X-Git-Url: http://git.roojs.org/?p=Pman.Core;a=commitdiff_plain;h=0f051553a65f31981af05b560e0baf9cf6998781 DataObjects/Core_notify.php --- diff --git a/DataObjects/Core_notify.php b/DataObjects/Core_notify.php index da8a9f01..e5c17ee7 100644 --- a/DataObjects/Core_notify.php +++ b/DataObjects/Core_notify.php @@ -52,7 +52,10 @@ class Pman_Core_DataObjects_Core_notify extends DB_DataObject { if ($set !== false) { $this->person_table = is_object($set) ? $set->tableName() : ''; - $col = $this->person_table == "Person" ? 'person_id' : $person_table . '_id'; + + $person_table = empty($this->person_table) ? 'Person' : $this->person_table; + $col = $person_table == "Person" ? 'person_id' : $person_table . '_id'; + $this->{$col} = is_object($set) ? $set->id : $set; return; }