instanceof instead of is_a is faster (thanks quix0r)

This commit is contained in:
Mikael Nordfeldth 2013-09-19 16:37:39 +02:00
parent 792e1aeb47
commit a35344eb00

View File

@ -89,7 +89,7 @@ class Profile extends Managed_DataObject
if ($this->_user === -1) {
$this->_user = User::getKV('id', $this->id);
}
if (!is_a($this->_user, 'User')) {
if (!($this->_user instanceof User)) {
throw new NoSuchUserException(array('id'=>$this->id));
}