From: Evan Prodromou Date: Sat, 10 Apr 2010 15:36:23 +0000 (-0400) Subject: catch UserNoProfileException and continue X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=5d96cf2eec15dc08af5c539be53b427c50ef89a9;p=quix0rs-gnu-social.git catch UserNoProfileException and continue --- diff --git a/lib/deluserqueuehandler.php b/lib/deluserqueuehandler.php index 4a1233a5ef..7103039382 100644 --- a/lib/deluserqueuehandler.php +++ b/lib/deluserqueuehandler.php @@ -49,9 +49,13 @@ class DelUserQueueHandler extends QueueHandler return true; } - if (!$user->hasRole(Profile_role::DELETED)) { - common_log(LOG_INFO, "User {$user->nickname} is not pending deletion; aborting."); - return true; + try { + if (!$user->hasRole(Profile_role::DELETED)) { + common_log(LOG_INFO, "User {$user->nickname} is not pending deletion; aborting."); + return true; + } + } catch (UserNoProfileException $unp) { + common_log(LOG_INFO, "Deleting user {$user->nickname} with no profile... probably a good idea!"); } $notice = $this->getNextBatch($user);