Merge pull request #12445 from MrPetovan/bug/12382-tag-attachment

Exclude [attachment] from tag search
This commit is contained in:
Philipp
2022-12-17 02:23:18 +01:00
committed by GitHub
+1 -1
View File
@@ -2355,7 +2355,7 @@ class BBCode
DI::profiler()->startRecording('rendering');
$ret = [];
self::performWithEscapedTags($string, ['noparse', 'pre', 'code', 'img'], function ($string) use (&$ret) {
self::performWithEscapedTags($string, ['noparse', 'pre', 'code', 'img', 'attachment'], function ($string) use (&$ret) {
// Convert hashtag links to hashtags
$string = preg_replace('/#\[url\=([^\[\]]*)\](.*?)\[\/url\]/ism', '#$2 ', $string);