]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/tagprofile.php
width and height are now properties in the File class
[quix0rs-gnu-social.git] / actions / tagprofile.php
index b4312ad4597b1cfbf0ef4a0a7c86ed16e92b2cf0..7538d7c8b6d62bdc0d9b5d2341f1eaf5e9bb32c5 100644 (file)
@@ -46,7 +46,6 @@ class TagprofileAction extends Action
             if (!$this->profile) {
                 // TRANS: Client error displayed when referring to non-existing profile ID.
                 $this->clientError(_('No profile with that ID.'));
-                return false;
             }
         }
 
@@ -55,7 +54,6 @@ class TagprofileAction extends Action
             // TRANS: Client error displayed when trying to tag a user that cannot be tagged.
             $this->clientError(_('You cannot tag this user.'));
         }
-        return true;
     }
 
     function handle($args)
@@ -94,7 +92,7 @@ class TagprofileAction extends Action
             $this->elementStart('body');
             $this->element('p', 'error', $error);
             $this->elementEnd('body');
-            $this->elementEnd('html');
+            $this->endHTML();
         } else {
             $this->showPage();
         }
@@ -107,8 +105,8 @@ class TagprofileAction extends Action
             // TRANS: Header in list form.
             $this->element('h2', null, _('User profile'));
 
-            $avatar = $this->profile->getAvatar(AVATAR_PROFILE_SIZE);
-            $this->element('img', array('src' => ($avatar) ? $avatar->displayUrl() : Avatar::defaultImage(AVATAR_PROFILE_SIZE),
+            $avatarUrl = $this->profile->avatarUrl(AVATAR_PROFILE_SIZE);
+            $this->element('img', array('src' => $avatarUrl,
                                         'class' => 'photo avatar entity_depiction',
                                         'width' => AVATAR_PROFILE_SIZE,
                                         'height' => AVATAR_PROFILE_SIZE,
@@ -238,7 +236,7 @@ class TagprofileAction extends Action
                 }
 
                 $this->elementEnd('body');
-                $this->elementEnd('html');
+                $this->endHTML();
             } else {
                 // TRANS: Success message if lists are saved.
                 $this->error = _('Lists saved.');