Webfingerの修正

This commit is contained in:
2026-01-20 17:10:15 +09:00
parent 2a0956dfd4
commit 22a7ca6ecb

View File

@@ -261,13 +261,14 @@ class ActivityPub {
*/ */
public function getWebfinger(): string { public function getWebfinger(): string {
if (!ACTIVITYPUB_ENABLED) return ''; if (!ACTIVITYPUB_ENABLED) return '';
$domain = str_replace(['http://', 'https://'], '', $this->domain);
$webfinger = [ $webfinger = [
'subject' => "acct:{$this->actor}@{$this->domain}", 'subject' => "acct:{$this->actor}@{$domain}",
'links' => [ 'links' => [
[ [
'rel' => 'self', 'rel' => 'self',
'type' => 'application/activity+json', 'type' => 'application/activity+json',
'href' => "{$this->domain}/ap/actor", 'href' => "{$domain}/ap/actor",
], ],
], ],
]; ];