Revert debugging code

This commit is contained in:
Brion Vibber 2009-12-30 16:40:59 -08:00
parent 9218cce3cd
commit ff50c2b91d
2 changed files with 0 additions and 14 deletions

View File

@ -31,20 +31,11 @@ class Memcached_DataObject extends DB_DataObject
function __destruct() function __destruct()
{ {
if (get_class($this) == 'Profile')
common_log(LOG_INFO, 'subbug: destructing result id ' . $this->_DB_resultid);
$this->free(); $this->free();
if (method_exists('DB_DataObject', '__destruct')) { if (method_exists('DB_DataObject', '__destruct')) {
parent::__destruct(); parent::__destruct();
} }
} }
function free()
{
if (get_class($this) == 'Profile')
common_log(LOG_INFO, 'subbug: freeing result id ' . $this->_DB_resultid);
parent::free();
}
function &staticGet($cls, $k, $v=null) function &staticGet($cls, $k, $v=null)
{ {

View File

@ -86,21 +86,16 @@ class ProfileList extends Widget
function showProfiles() function showProfiles()
{ {
$log = strtolower(get_class($this)) == 'subscriberslist' && $this->owner->nickname == 'petercook';
$cnt = 0; $cnt = 0;
if ($log) common_log(LOG_INFO, "subbug: starting with {$this->profile->N}");
while ($this->profile->fetch()) { while ($this->profile->fetch()) {
$cnt++; $cnt++;
if($cnt > PROFILES_PER_PAGE) { if($cnt > PROFILES_PER_PAGE) {
if ($log) common_log(LOG_INFO, "subbug: breaking at $cnt");
break; break;
} }
if ($log) common_log(LOG_INFO, "subbug: showing at $cnt");
$pli = $this->newListItem($this->profile); $pli = $this->newListItem($this->profile);
$pli->show(); $pli->show();
} }
if ($log) common_log(LOG_INFO, "subbug: ended at $cnt");
return $cnt; return $cnt;
} }