]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/showapplication.php
Removed 'bookmarklet' since we have Bookmark plugin
[quix0rs-gnu-social.git] / actions / showapplication.php
index adfd17a06cd5fbfeb9de95d92a1451028fc3ccb8..b44dd5746a09e49f6bfbd174f45ae04af9302e09 100644 (file)
@@ -71,19 +71,17 @@ class ShowApplicationAction extends Action
 
         $id = (int)$this->arg('id');
 
-        $this->application  = Oauth_application::staticGet($id);
-        $this->owner        = User::staticGet($this->application->owner);
+        $this->application  = Oauth_application::getKV($id);
+        $this->owner        = User::getKV($this->application->owner);
 
         if (!common_logged_in()) {
             // TRANS: Client error displayed trying to display an OAuth application while not logged in.
             $this->clientError(_('You must be logged in to view an application.'));
-            return false;
         }
 
         if (empty($this->application)) {
             // TRANS: Client error displayed trying to display a non-existing OAuth application.
             $this->clientError(_('No such application.'), 404);
-            return false;
         }
 
         $cur = common_current_user();
@@ -91,7 +89,6 @@ class ShowApplicationAction extends Action
         if ($cur->id != $this->owner->id) {
             // TRANS: Client error displayed trying to display an OAuth application for which the logged in user is not the owner.
             $this->clientError(_('You are not the owner of this application.'), 401);
-            return false;
         }
 
         return true;
@@ -115,7 +112,6 @@ class ShowApplicationAction extends Action
             if (!$token || $token != common_session_token()) {
                 // TRANS: Client error displayed when the session token does not match or is not given.
                 $this->clientError(_('There was a problem with your session token.'));
-                return;
             }
 
             if ($this->arg('reset')) {
@@ -174,7 +170,7 @@ class ShowApplicationAction extends Action
         $this->elementStart('div', 'entity_statistics');
         $defaultAccess = ($this->application->access_type & Oauth_application::$writeAccess)
             ? 'read-write' : 'read-only';
-        $profile = Profile::staticGet($this->application->owner);
+        $profile = Profile::getKV($this->application->owner);
 
         $appUsers = new Oauth_application_user();
         $appUsers->application_id = $this->application->id;
@@ -261,13 +257,13 @@ class ShowApplicationAction extends Action
         $this->element('dd', null, $consumer->consumer_secret);
         // TRANS: Field label on application page.
         $this->element('dt', null, _('Request token URL'));
-        $this->element('dd', null, common_local_url('ApiOauthRequestToken'));
+        $this->element('dd', null, common_local_url('ApiOAuthRequestToken'));
         // TRANS: Field label on application page.
         $this->element('dt', null, _('Access token URL'));
-        $this->element('dd', null, common_local_url('ApiOauthAccessToken'));
+        $this->element('dd', null, common_local_url('ApiOAuthAccessToken'));
         // TRANS: Field label on application page.
         $this->element('dt', null, _('Authorize URL'));
-        $this->element('dd', null, common_local_url('ApiOauthAuthorize'));
+        $this->element('dd', null, common_local_url('ApiOAuthAuthorize'));
         $this->elementEnd('dl');
 
         $this->element('p', 'note',