]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - lib/messagelistitem.php
Properly unlink all old avatars when deleting/uploading a new
[quix0rs-gnu-social.git] / lib / messagelistitem.php
index 9c9a0335c61d00f1dd7f5fb84f784efadb4f6493..2590d7df634c9d76e4aa9042ef840f82f7fbe62c 100644 (file)
@@ -76,10 +76,8 @@ abstract class MessageListItem extends Widget
         $this->out->elementStart('span', 'vcard author');
         $this->out->elementStart('a', array('href' => $profile->profileurl,
                                             'class' => 'url'));
-        $avatar = $profile->getAvatar(AVATAR_STREAM_SIZE);
-        $this->out->element('img', array('src' => ($avatar) ?
-                                         $avatar->displayUrl() :
-                                         Avatar::defaultImage(AVATAR_STREAM_SIZE),
+        $avatarUrl = $profile->avatarUrl(AVATAR_STREAM_SIZE);
+        $this->out->element('img', array('src' => $avatarUrl,
                                          'class' => 'photo avatar',
                                          'width' => AVATAR_STREAM_SIZE,
                                          'height' => AVATAR_STREAM_SIZE,