X-Git-Url: https://git.openstreetmap.org./osqa.git/blobdiff_plain/97d088726443a6b1c682cf629b5662c54bfbb291..fd5174ac564e77cabc5e1a5919f2d29f426fb261:/forum/utils/userlinking.py?ds=sidebyside diff --git a/forum/utils/userlinking.py b/forum/utils/userlinking.py index 39f8bbb..6693883 100644 --- a/forum/utils/userlinking.py +++ b/forum/utils/userlinking.py @@ -1,6 +1,6 @@ import re -from forum.models import User, Question, Answer, Comment +from forum.models.user import User def find_best_match_in_name(content, uname, fullname, start_index): end_index = start_index + len(fullname) @@ -17,23 +17,11 @@ def find_best_match_in_name(content, uname, fullname, start_index): return uname -APPEAL_PATTERN = re.compile(r'@\w+') +APPEAL_PATTERN = re.compile(r'(?