Removed the free calls (unneeded since destructors now work), and added an error check w/ logging & an exception for future attempts to forward calls to nonexistent object.
}
}
- $subscribers->free();
-
$this->pagination($this->page > 1, $cnt > PROFILES_PER_PAGE,
$this->page, 'subscribers',
array('nickname' => $this->user->nickname));
}
}
- $subscriptions->free();
-
$this->pagination($this->page > 1, $cnt > PROFILES_PER_PAGE,
$this->page, 'subscriptions',
array('nickname' => $this->user->nickname));
function __call($name, $args)
{
$item =& $this->_items[$this->_i];
+ if (!is_object($item)) {
+ common_log(LOG_ERR, "Invalid entry " . var_export($item, true) . " at index $this->_i of $this->N; calling $name()");
+ throw new ServerException("Internal error: bad entry in array wrapper list.");
+ }
return call_user_func_array(array($item, $name), $args);
}
}