Test user equality better in Profile->getUser()
This commit is contained in:
parent
d7a29be3ac
commit
a62755182c
@ -94,7 +94,7 @@ class Profile extends Managed_DataObject
|
|||||||
throw new NoSuchUserException(array('id'=>$this->id));
|
throw new NoSuchUserException(array('id'=>$this->id));
|
||||||
}
|
}
|
||||||
$cur_user = common_current_user();
|
$cur_user = common_current_user();
|
||||||
if ($user->id === $cur_user->id) {
|
if (($cur_user instanceof User) && $cur_user->sameAS($this)) {
|
||||||
$user = $cur_user;
|
$user = $cur_user;
|
||||||
}
|
}
|
||||||
$this->_user[$this->id] = $user;
|
$this->_user[$this->id] = $user;
|
||||||
|
Loading…
Reference in New Issue
Block a user