Merge pull request #2621 from tractorcow/pulls/3.1-undefined-index

BUG Fix undefined index ID
This commit is contained in:
Ingo Schommer 2013-10-29 15:26:34 -07:00
commit ba1e688729

View File

@ -639,7 +639,7 @@ class DataObject extends ViewableData implements DataObjectInterface, i18nEntity
* @return boolean true if this object exists
*/
public function exists() {
return ($this->record && $this->record['ID'] > 0);
return (isset($this->record['ID']) && $this->record['ID'] > 0);
}
/**