Merge pull request #1878 from annando/1509-nodeinfo

The links for nodeinfo in "well-known" need to be an array of objects.
This commit is contained in:
Tobias Diekershoff 2015-09-05 07:39:49 +02:00
commit 7dbd8ed473
1 changed files with 2 additions and 2 deletions

View File

@ -10,8 +10,8 @@ function nodeinfo_wellknown(&$a) {
http_status_exit(404); http_status_exit(404);
killme(); killme();
} }
$nodeinfo = array("links" => array("rel" => "http://nodeinfo.diaspora.software/ns/schema/1.0", $nodeinfo = array("links" => array(array("rel" => "http://nodeinfo.diaspora.software/ns/schema/1.0",
"href" => $a->get_baseurl()."/nodeinfo/1.0")); "href" => $a->get_baseurl()."/nodeinfo/1.0")));
header('Content-type: application/json; charset=utf-8'); header('Content-type: application/json; charset=utf-8');
echo json_encode($nodeinfo, JSON_PRETTY_PRINT|JSON_UNESCAPED_SLASHES); echo json_encode($nodeinfo, JSON_PRETTY_PRINT|JSON_UNESCAPED_SLASHES);