mirror of
https://github.com/friendica/friendica
synced 2024-11-18 01:03:40 +00:00
Merge pull request #14372 from zotanmew/patch-1
Return rel=self link for xrd+xml webfinger responses
This commit is contained in:
commit
10eadd5cf5
1 changed files with 15 additions and 8 deletions
|
@ -272,57 +272,64 @@ class Xrd extends BaseModule
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
'4:link' => [
|
'4:link' => [
|
||||||
|
'@attributes' => [
|
||||||
|
'rel' => 'self',
|
||||||
|
'type' => 'application/activity+json',
|
||||||
|
'href' => $owner['url']
|
||||||
|
]
|
||||||
|
],
|
||||||
|
'5:link' => [
|
||||||
'@attributes' => [
|
'@attributes' => [
|
||||||
'rel' => ActivityNamespace::HCARD,
|
'rel' => ActivityNamespace::HCARD,
|
||||||
'type' => 'text/html',
|
'type' => 'text/html',
|
||||||
'href' => $baseURL . '/hcard/' . $owner['nickname']
|
'href' => $baseURL . '/hcard/' . $owner['nickname']
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
'5:link' => [
|
'6:link' => [
|
||||||
'@attributes' => [
|
'@attributes' => [
|
||||||
'rel' => ActivityNamespace::WEBFINGERAVATAR,
|
'rel' => ActivityNamespace::WEBFINGERAVATAR,
|
||||||
'type' => $avatar['type'],
|
'type' => $avatar['type'],
|
||||||
'href' => User::getAvatarUrl($owner)
|
'href' => User::getAvatarUrl($owner)
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
'6:link' => [
|
'7:link' => [
|
||||||
'@attributes' => [
|
'@attributes' => [
|
||||||
'rel' => ActivityNamespace::DIASPORA_SEED,
|
'rel' => ActivityNamespace::DIASPORA_SEED,
|
||||||
'type' => 'text/html',
|
'type' => 'text/html',
|
||||||
'href' => $baseURL
|
'href' => $baseURL
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
'7:link' => [
|
'8:link' => [
|
||||||
'@attributes' => [
|
'@attributes' => [
|
||||||
'rel' => 'salmon',
|
'rel' => 'salmon',
|
||||||
'href' => $baseURL . '/salmon/' . $owner['nickname']
|
'href' => $baseURL . '/salmon/' . $owner['nickname']
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
'8:link' => [
|
'9:link' => [
|
||||||
'@attributes' => [
|
'@attributes' => [
|
||||||
'rel' => 'http://salmon-protocol.org/ns/salmon-replies',
|
'rel' => 'http://salmon-protocol.org/ns/salmon-replies',
|
||||||
'href' => $baseURL . '/salmon/' . $owner['nickname']
|
'href' => $baseURL . '/salmon/' . $owner['nickname']
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
'9:link' => [
|
'10:link' => [
|
||||||
'@attributes' => [
|
'@attributes' => [
|
||||||
'rel' => 'http://salmon-protocol.org/ns/salmon-mention',
|
'rel' => 'http://salmon-protocol.org/ns/salmon-mention',
|
||||||
'href' => $baseURL . '/salmon/' . $owner['nickname'] . '/mention'
|
'href' => $baseURL . '/salmon/' . $owner['nickname'] . '/mention'
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
'10:link' => [
|
'11:link' => [
|
||||||
'@attributes' => [
|
'@attributes' => [
|
||||||
'rel' => ActivityNamespace::OSTATUSSUB,
|
'rel' => ActivityNamespace::OSTATUSSUB,
|
||||||
'template' => $baseURL . '/contact/follow?url={uri}'
|
'template' => $baseURL . '/contact/follow?url={uri}'
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
'11:link' => [
|
'12:link' => [
|
||||||
'@attributes' => [
|
'@attributes' => [
|
||||||
'rel' => 'magic-public-key',
|
'rel' => 'magic-public-key',
|
||||||
'href' => 'data:application/magic-public-key,' . Salmon::salmonKey($owner['spubkey'])
|
'href' => 'data:application/magic-public-key,' . Salmon::salmonKey($owner['spubkey'])
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
'12:link' => [
|
'13:link' => [
|
||||||
'@attributes' => [
|
'@attributes' => [
|
||||||
'rel' => ActivityNamespace::OPENWEBAUTH,
|
'rel' => ActivityNamespace::OPENWEBAUTH,
|
||||||
'type' => 'application/x-zot+json',
|
'type' => 'application/x-zot+json',
|
||||||
|
|
Loading…
Reference in a new issue