From af38d22d38885522c617eb238ad966772e79d686 Mon Sep 17 00:00:00 2001 From: Alexandre Alapetite Date: Fri, 16 Nov 2018 23:52:36 +0100 Subject: [PATCH] Fix ATOM feed title encoding Was HTML-encoded instead of plain Unicode. Fixed only for feed_mode. Probably wrong as well for non_feed mode (not sure how to test) --- src/Protocol/OStatus.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Protocol/OStatus.php b/src/Protocol/OStatus.php index d65624664..557277fe8 100644 --- a/src/Protocol/OStatus.php +++ b/src/Protocol/OStatus.php @@ -1945,7 +1945,11 @@ class OStatus } XML::addElement($doc, $entry, "id", $item["uri"]); - XML::addElement($doc, $entry, "title", $title); + if ($feed_mode) { + XML::addElement($doc, $entry, "title", html_entity_decode($title, ENT_QUOTES, 'UTF-8')); + } else { + XML::addElement($doc, $entry, "title", $title); + } $body = self::formatPicturePost($item['body']);