Support hashtags with mentions.

This commit is contained in:
John Preston
2024-10-11 09:31:03 +04:00
parent f89aeb6ad4
commit 7ee2e3d8bc
6 changed files with 42 additions and 1 deletions

View File

@@ -2722,7 +2722,9 @@ std::optional<RecentHashtagPack> Account::saveRecentHashtags(
auto found = false;
auto m = QRegularExpressionMatch();
auto recent = getPack();
for (auto i = 0, next = 0; (m = TextUtilities::RegExpHashtag(false).match(text, i)).hasMatch(); i = next) {
for (auto i = 0, next = 0
; (m = TextUtilities::RegExpHashtag(false).match(text, i)).hasMatch()
; i = next) {
i = m.capturedStart();
next = m.capturedEnd();
if (m.hasMatch()) {