From 15d24a77c7908bc8b562ca871dde0e1a0625ec04 Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Thu, 24 Aug 2023 09:29:15 -0400 Subject: [PATCH] Replace author name by server host in Ignore Server labels --- src/Content/Item.php | 2 +- src/Object/Post.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Content/Item.php b/src/Content/Item.php index f2b4d9600b..163db89aa4 100644 --- a/src/Content/Item.php +++ b/src/Content/Item.php @@ -435,7 +435,7 @@ class Item $this->l10n->t('Block') => $block_link, $this->l10n->t('Ignore') => $ignore_link, $this->l10n->t('Collapse') => $collapse_link, - $this->l10n->t("Ignore %s's server", $item['author-name']) => $ignoreserver_link, + $this->l10n->t("Ignore %s server", $authorBaseUri->getHost()) => $ignoreserver_link, ]; if (!empty($item['language'])) { diff --git a/src/Object/Post.php b/src/Object/Post.php index 565dc0d10d..dd3074cfa3 100644 --- a/src/Object/Post.php +++ b/src/Object/Post.php @@ -285,7 +285,7 @@ class Post $authorBaseUri = new Uri($item['author-baseurl'] ?? ''); if ($authorBaseUri->getHost() && !DI::baseUrl()->isLocalUrl($authorBaseUri)) { $ignoreServer = [ - 'label' => DI::l10n()->t("Ignore %s's server", $item['author-name']), + 'label' => DI::l10n()->t("Ignore %s server", $authorBaseUri->getHost()), ]; } }