about summary refs log tree commit diff
path: root/app
diff options
context:
space:
mode:
authorThibG <thib@sitedethib.com>2020-03-08 15:42:20 +0100
committerGitHub <noreply@github.com>2020-03-08 15:42:20 +0100
commit6185bff4b3c2fec7b84aee8a9d6747d42ad865c0 (patch)
tree18744535fc6270e8a4f93fae8370e625dd1a1449 /app
parent4a4cd686c1d556e7b5246ddc309085243b4a051b (diff)
Fix error when searching for URLs that contain the mention syntax (#13151)
Fixes #13150
Diffstat (limited to 'app')
-rw-r--r--app/services/account_search_service.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/account_search_service.rb b/app/services/account_search_service.rb
index d217dabb3..493813aab 100644
--- a/app/services/account_search_service.rb
+++ b/app/services/account_search_service.rb
@@ -171,7 +171,7 @@ class AccountSearchService < BaseService
   end
 
   def username_complete?
-    query.include?('@') && "@#{query}" =~ Account::MENTION_RE
+    query.include?('@') && "@#{query}" =~ /\A#{Account::MENTION_RE}\Z/
   end
 
   def likely_acct?