From b800083a2b6a3304c390daefdd3710ade1c0edbe Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Fri, 13 Dec 2019 07:16:43 -0500 Subject: [PATCH] Don't process empty hash tags in Model\Item - Addresses https://github.com/friendica/friendica/issues/7677#issuecomment-565372628 --- src/Model/Item.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Model/Item.php b/src/Model/Item.php index 5427ff44b..ebee91ffc 100644 --- a/src/Model/Item.php +++ b/src/Model/Item.php @@ -2621,7 +2621,7 @@ class Item extends BaseObject "#$2", $item["body"]); foreach ($tags as $tag) { - if ((strpos($tag, '#') !== 0) || strpos($tag, '[url=') || $tag[1] == '#') { + if ((strpos($tag, '#') !== 0) || strpos($tag, '[url=') || strlen($tag) < 2 || $tag[1] == '#') { continue; }