diff options
author | Corey Hulen <corey@hulen.com> | 2015-06-19 10:39:35 -0800 |
---|---|---|
committer | Corey Hulen <corey@hulen.com> | 2015-06-19 10:39:35 -0800 |
commit | ce0741c0b3dc99384e20f13829fa58754bfb479c (patch) | |
tree | be00a4631123ef3d28bd40912df0f17a53309d6d /model/utils.go | |
parent | 213129255d4b1eba056806665a6309e109b531d9 (diff) | |
parent | 5aef020ca2684a816fce8bc22b0b53ffd594756c (diff) | |
download | chat-ce0741c0b3dc99384e20f13829fa58754bfb479c.tar.gz chat-ce0741c0b3dc99384e20f13829fa58754bfb479c.tar.bz2 chat-ce0741c0b3dc99384e20f13829fa58754bfb479c.zip |
Merge pull request #36 from mattermost/notification-fix
HELIUM fix a bug where mentions wouldn't update for words after certain characters
Diffstat (limited to 'model/utils.go')
-rw-r--r-- | model/utils.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/model/utils.go b/model/utils.go index 2541247de..262bda319 100644 --- a/model/utils.go +++ b/model/utils.go @@ -319,3 +319,5 @@ func ClearMentionTags(post string) string { var UrlRegex = regexp.MustCompile(`^((?:[a-z]+:\/\/)?(?:(?:[a-z0-9\-]+\.)+(?:[a-z]{2}|aero|arpa|biz|com|coop|edu|gov|info|int|jobs|mil|museum|name|nato|net|org|pro|travel|local|internal))(:[0-9]{1,5})?(?:\/[a-z0-9_\-\.~]+)*(\/([a-z0-9_\-\.]*)(?:\?[a-z0-9+_~\-\.%=&]*)?)?(?:#[a-zA-Z0-9!$&'()*+.=-_~:@/?]*)?)(?:\s+|$)$`) var PartialUrlRegex = regexp.MustCompile(`/api/v1/files/(get|get_image)/([A-Za-z0-9]{26})/([A-Za-z0-9]{26})/(([A-Za-z0-9]+/)?.+\.[A-Za-z0-9]{3,})`) + +var SplitRunes = map[rune]bool{',': true, ' ': true, '.': true, '!': true, '?': true, ':': true, ';': true, '\n': true, '<': true, '>': true, '(': true, ')': true, '{': true, '}': true, '[': true, ']': true, '+': true, '/': true, '\\': true} |