]> git.mxchange.org Git - friendica.git/blobdiff - mod/xrd.php
Storing the protocol while following a contact
[friendica.git] / mod / xrd.php
index 1611540a6c4955990beb48644f7c1851adb7abd2..b4cb60afed68c7b1c80b27a61cc0e84ab8b90a07 100644 (file)
@@ -4,7 +4,7 @@
  */
 
 use Friendica\App;
-use Friendica\Core\Addon;
+use Friendica\Core\Hook;
 use Friendica\Core\Renderer;
 use Friendica\Core\System;
 use Friendica\Database\DBA;
@@ -63,13 +63,13 @@ function xrd_init(App $a)
        }
 
        if ($mode == 'xml') {
-               xrd_xml($a, $addr, $alias, $profile_url, $user);
+               xrd_xml($addr, $alias, $profile_url, $user);
        } else {
-               xrd_json($a, $addr, $alias, $profile_url, $user);
+               xrd_json($addr, $alias, $profile_url, $user);
        }
 }
 
-function xrd_json($a, $uri, $alias, $profile_url, $r)
+function xrd_json($uri, $alias, $profile_url, $r)
 {
        $salmon_key = Salmon::salmonKey($r['spubkey']);
 
@@ -97,10 +97,10 @@ function xrd_json($a, $uri, $alias, $profile_url, $r)
        ];
 
        echo json_encode($json);
-       killme();
+       exit();
 }
 
-function xrd_xml($a, $uri, $alias, $profile_url, $r)
+function xrd_xml($uri, $alias, $profile_url, $r)
 {
        $salmon_key = Salmon::salmonKey($r['spubkey']);
 
@@ -127,8 +127,8 @@ function xrd_xml($a, $uri, $alias, $profile_url, $r)
        );
 
        $arr = ['user' => $r, 'xml' => $o];
-       Addon::callHooks('personal_xrd', $arr);
+       Hook::callAll('personal_xrd', $arr);
 
        echo $arr['xml'];
-       killme();
+       exit();
 }