Make sure something's an int before comparing to -1

This commit is contained in:
Evan Prodromou
2011-04-09 15:34:33 -04:00
parent 285c2ee72d
commit 070b07632b
3 changed files with 3 additions and 3 deletions

View File

@@ -56,7 +56,7 @@ class Profile extends Memcached_DataObject
function getUser()
{
if ($this->_user == -1) {
if (is_int($this->_user) && $this->_user == -1) {
$this->_user = User::staticGet('id', $this->id);
}