X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=actions%2Fuserrss.php;h=239b5e517455b3eebcf01c8b422bbf5e2fd5ed75;hb=b0dfc70a54e5e184023ed982dfaf5439041e9708;hp=a688cbf371f2f0ceb2b1aa63ea17913a85eefd32;hpb=a7e748479c273ddecfe9fdbd72670fe1abe766bf;p=quix0rs-gnu-social.git diff --git a/actions/userrss.php b/actions/userrss.php index a688cbf371..239b5e5174 100644 --- a/actions/userrss.php +++ b/actions/userrss.php @@ -102,14 +102,12 @@ class UserrssAction extends Rss10Action { $user = $this->user; $profile = $user->getProfile(); - if (!$profile) { - common_log_db_error($user, 'SELECT', __FILE__); - // TRANS: Error message displayed when referring to a user without a profile. - $this->serverError(_('User has no profile.')); + try { + $avatar = $profile->getAvatar(AVATAR_PROFILE_SIZE); + return $avatar->url; + } catch (Exception $e) { return null; } - $avatar = $profile->getAvatar(AVATAR_PROFILE_SIZE); - return ($avatar) ? $avatar->url : null; } // override parent to add X-SUP-ID URL