summaryrefslogtreecommitdiffstats
path: root/web
diff options
context:
space:
mode:
authorhmhealey <harrisonmhealey@gmail.com>2015-11-06 12:06:20 -0500
committerhmhealey <harrisonmhealey@gmail.com>2015-11-06 12:06:20 -0500
commit11d6644c5325a5686824bef7ffc66778f48acf07 (patch)
tree62e274fd4f1aa39f02316e31d14069f2a373fffb /web
parent9f9c8cb62c6b81fe67441cdf113b9a4b4b456066 (diff)
downloadchat-11d6644c5325a5686824bef7ffc66778f48acf07.tar.gz
chat-11d6644c5325a5686824bef7ffc66778f48acf07.tar.bz2
chat-11d6644c5325a5686824bef7ffc66778f48acf07.zip
Changed markdown text regex to capture whitespace preceeding an underscore
Diffstat (limited to 'web')
-rw-r--r--web/react/utils/markdown.jsx2
1 files changed, 1 insertions, 1 deletions
diff --git a/web/react/utils/markdown.jsx b/web/react/utils/markdown.jsx
index 374caf6dc..e293b9c7f 100644
--- a/web/react/utils/markdown.jsx
+++ b/web/react/utils/markdown.jsx
@@ -24,7 +24,7 @@ class MattermostInlineLexer extends marked.InlineLexer {
// modified version of the regex that doesn't break up words in snake_case,
// allows for links starting with www, and allows links succounded by parentheses
// the original is /^[\s\S]+?(?=[\\<!\[_*`~]|https?:\/\/| {2,}\n|$)/
- this.rules.text = /^[\s\S]+?(?=[^\w\/]_|[\\<!\[*`~]|https?:\/\/|www\.|\(| {2,}\n|$)/;
+ this.rules.text = /^[\s\S]+?(?:[^\w\/](?=_)|(?=[\\<!\[*`~]|https?:\/\/|www\.|\(| {2,}\n|$))/;
// modified version of the regex that allows links starting with www and those surrounded
// by parentheses