aboutsummaryrefslogtreecommitdiffstats
path: root/modules/markdown
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2016-07-23 17:29:34 +0800
committerUnknwon <u@gogs.io>2016-07-23 17:29:34 +0800
commitd7bdc1de8d98d7f58971f822e10c1650a450b194 (patch)
tree0ede4eb3fe01849254e25a4bac7923dcffcc12a1 /modules/markdown
parentc912494609470f10401594391c6f2763684cb624 (diff)
downloadgitea-d7bdc1de8d98d7f58971f822e10c1650a450b194.tar.gz
gitea-d7bdc1de8d98d7f58971f822e10c1650a450b194.zip
#3107 fix mention regex does not include dash
Diffstat (limited to 'modules/markdown')
-rw-r--r--modules/markdown/markdown.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/markdown/markdown.go b/modules/markdown/markdown.go
index d49c14d1f9..20fe2a77fe 100644
--- a/modules/markdown/markdown.go
+++ b/modules/markdown/markdown.go
@@ -75,7 +75,7 @@ func IsReadmeFile(name string) bool {
var (
// MentionPattern matches string that mentions someone, e.g. @Unknwon
- MentionPattern = regexp.MustCompile(`(\s|^)@[0-9a-zA-Z_\.]+`)
+ MentionPattern = regexp.MustCompile(`(\s|^)@[0-9a-zA-Z-_\.]+`)
// CommitPattern matches link to certain commit with or without trailing hash,
// e.g. https://try.gogs.io/gogs/gogs/commit/d8a994ef243349f321568f9e36d5c3f444b99cae#diff-2