Notice metadata for WebFinger. Not sure if implemented properly.

This is more of a proof of concept and will likely not stay in exactly
this form. We should reasonably deliver the entire notice upon webfinger
querying.
This commit is contained in:
Mikael Nordfeldth
2013-11-01 16:54:59 +01:00
parent 7ddd561837
commit 6ef1967cec
5 changed files with 36 additions and 12 deletions

View File

@@ -1311,6 +1311,14 @@ class OStatusPlugin extends Plugin
}
}
function onEndWebFingerNoticeLinks(XML_XRD $xrd, Notice $target)
{
$author = $target->getProfile();
$salmon_url = common_local_url('usersalmon', array('id' => $author->id));
$xrd->links[] = new XML_XRD_Element_Link(Salmon::REL_SALMON, $salmon_url);
return true;
}
function onEndWebFingerProfileLinks(XML_XRD $xrd, Profile $target)
{
$xrd->links[] = new XML_XRD_Element_Link(Discovery::UPDATESFROM,