]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - lib/profilelist.php
Properly unlink all old avatars when deleting/uploading a new
[quix0rs-gnu-social.git] / lib / profilelist.php
index 313cf760731e9a72a41e2ffe5966269a7d01bd96..085690b9f7f4a33805789d42565e3f1d71ef1299 100644 (file)
@@ -199,10 +199,10 @@ class ProfileListItem extends Widget
 
     function showAvatar()
     {
-        $avatar = $this->profile->getAvatar(AVATAR_STREAM_SIZE);
+        $avatarUrl = $this->profile->avatarUrl(AVATAR_STREAM_SIZE);
         $aAttrs = $this->linkAttributes();
         $this->out->elementStart('a', $aAttrs);
-        $this->out->element('img', array('src' => (!empty($avatar)) ? $avatar->displayUrl() : Avatar::defaultImage(AVATAR_STREAM_SIZE),
+        $this->out->element('img', array('src' => $avatarUrl,
                                          'class' => 'photo avatar',
                                          'width' => AVATAR_STREAM_SIZE,
                                          'height' => AVATAR_STREAM_SIZE,