From 341a4a8ee54ffb2cd4ec025907cf88182756cd04 Mon Sep 17 00:00:00 2001 From: Laura Hausmann Date: Mon, 26 Feb 2024 20:24:56 +0100 Subject: [PATCH] [backend/libmfm] Further improve mfm mentions parser --- Iceshrimp.Backend/Core/Helpers/LibMfm/Parsing/MfmParser.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Iceshrimp.Backend/Core/Helpers/LibMfm/Parsing/MfmParser.cs b/Iceshrimp.Backend/Core/Helpers/LibMfm/Parsing/MfmParser.cs index 2dc46bbd..6611625f 100644 --- a/Iceshrimp.Backend/Core/Helpers/LibMfm/Parsing/MfmParser.cs +++ b/Iceshrimp.Backend/Core/Helpers/LibMfm/Parsing/MfmParser.cs @@ -280,7 +280,7 @@ internal class HashtagNodeParser : INodeParser internal class MentionNodeParser : INodeParser { private const string Pre = "@"; - private static readonly Regex Post = new(@"[\s\),:]|$"); + private static readonly Regex Post = new(@"[\s\),']|:(?:[^a-zA-Z]|)|$"); private static readonly Regex Full = new(@"^[a-zA-Z0-9._\-]+(?:@[a-zA-Z0-9._\-]+\.[a-zA-Z0-9._\-]+)?$"); private static readonly Regex Lookbehind = new(@"\s");