mirror of
https://github.com/gogs/gogs.git
synced 2026-03-09 21:50:28 +01:00
markdown: fix mailto: doesn't recognize as valid link (#3790)
This commit is contained in:
@@ -43,7 +43,7 @@ func BuildSanitizer() {
|
||||
Sanitizer.AllowURLSchemes(setting.Markdown.CustomURLSchemes...)
|
||||
}
|
||||
|
||||
var validLinksPattern = regexp.MustCompile(`^[a-z][\w-]+://`)
|
||||
var validLinksPattern = regexp.MustCompile(`^[a-z][\w-]+://|^mailto:`)
|
||||
|
||||
// isLink reports whether link fits valid format.
|
||||
func isLink(link []byte) bool {
|
||||
|
||||
Reference in New Issue
Block a user