diff options
Diffstat (limited to 'web/react/utils/markdown.jsx')
-rw-r--r-- | web/react/utils/markdown.jsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/web/react/utils/markdown.jsx b/web/react/utils/markdown.jsx index 12d6dd424..2813798d2 100644 --- a/web/react/utils/markdown.jsx +++ b/web/react/utils/markdown.jsx @@ -32,7 +32,7 @@ export class MattermostMarkdownRenderer extends marked.Renderer { link(href, title, text) { let outHref = href; - if (outHref.lastIndexOf('http', 0) !== 0) { + if (!(/^(mailto|https?|ftp)/.test(outHref))) { outHref = `http://${outHref}`; } |