From 4a6d17ad7bfea59d451b64b90eb794055c965557 Mon Sep 17 00:00:00 2001 From: Claire Date: Tue, 17 Feb 2026 11:27:36 +0100 Subject: [PATCH] Fix hashtag matching by replacing negative lookbehind with positive lookbehind (#37684) --- app/models/tag.rb | 2 +- spec/models/tag_spec.rb | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/app/models/tag.rb b/app/models/tag.rb index 9924d132e6..9c4e0510a9 100644 --- a/app/models/tag.rb +++ b/app/models/tag.rb @@ -41,7 +41,7 @@ class Tag < ApplicationRecord HASHTAG_LAST_SEQUENCE = '([[:word:]_]*[[:alpha:]][[:word:]_]*)' HASHTAG_NAME_PAT = "#{HASHTAG_FIRST_SEQUENCE}|#{HASHTAG_LAST_SEQUENCE}".freeze - HASHTAG_RE = %r{(?