]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/rsd.php
Merge branch 'nightly' into 'nightly'
[quix0rs-gnu-social.git] / actions / rsd.php
index f99b86e1a4035fb8c9a68393299e8023c32e9f8a..0feab73c28b23c29f6c04ec06406c06436696a1d 100644 (file)
@@ -85,7 +85,7 @@ class RsdAction extends Action
      *
      * @return boolean success flag
      */
-    function prepare($args)
+    function prepare(array $args = array())
     {
         parent::prepare($args);
 
@@ -101,18 +101,14 @@ class RsdAction extends Action
             // Permanent redirect on non-canonical nickname
 
             if ($nickname_arg != $nickname) {
-                common_redirect(common_local_url('rsd',
-                                                 array('nickname' => $nickname)),
-                                301);
-                return false;
+                common_redirect(common_local_url('rsd', array('nickname' => $nickname)), 301);
             }
 
-            $this->user = User::staticGet('nickname', $nickname);
+            $this->user = User::getKV('nickname', $nickname);
 
             if (empty($this->user)) {
                 // TRANS: Client error.
                 $this->clientError(_('No such user.'), 404);
-                return false;
             }
         }
 
@@ -130,7 +126,7 @@ class RsdAction extends Action
      *
      * @return nothing
      */
-    function handle($args)
+    function handle()
     {
         header('Content-Type: application/rsd+xml');
 
@@ -155,7 +151,7 @@ class RsdAction extends Action
             $this->elementStart('api', $apiAttrs);
             $this->elementStart('settings');
             $this->element('docs', null,
-                           'http://status.net/wiki/TwitterCompatibleAPI');
+                           common_local_url('doc', array('title' => 'api')));
             $this->element('setting', array('name' => 'OAuth'),
                            'true');
             $this->elementEnd('settings');