BUG: DataObject::__construct() now accepts stdClass for $record

This commit is contained in:
Justin Martin 2012-11-01 16:57:07 -07:00
parent 43cd54bb25
commit a651d730f2

View File

@ -323,7 +323,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
);
}
if(!is_array($record)) {
if(!is_array($record) && !is_a($record, "stdClass")) {
if(is_object($record)) $passed = "an object of type '$record->class'";
else $passed = "The value '$record'";