]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - plugins/OStatus/lib/xrdaction.php
Merge branch '0.9.x' into 1.0.x
[quix0rs-gnu-social.git] / plugins / OStatus / lib / xrdaction.php
index f1a56e0a84d3b3967b2595d32f2f3f82afd12ed2..c8b5beff379732d7bee653324071558e9035ffd2 100644 (file)
@@ -26,13 +26,12 @@ if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); }
 
 class XrdAction extends Action
 {
-
     public $uri;
-    
+
     public $user;
 
     public $xrd;
-    
+
     function handle()
     {
         $nick =  $this->user->nickname;
@@ -76,6 +75,9 @@ class XrdAction extends Action
         $salmon_url = common_local_url('usersalmon',
                                        array('id' => $this->user->id));
 
+        $xrd->links[] = array('rel' => Salmon::REL_SALMON,
+                              'href' => $salmon_url);
+        // XXX : Deprecated - to be removed.
         $xrd->links[] = array('rel' => Salmon::NS_REPLIES,
                               'href' => $salmon_url);
 
@@ -98,8 +100,7 @@ class XrdAction extends Action
         $xrd->links[] = array('rel' => 'http://ostatus.org/schema/1.0/subscribe',
                               'template' => $url );
 
-        header('Content-type: text/xml');
+        header('Content-type: application/xrd+xml');
         print $xrd->toXML();
     }
-
 }