Fixed external links to open in a new tab (#2793)

This commit is contained in:
Harrison Healey
2016-04-25 10:46:34 -04:00
committed by Joram Wilander
parent 5f7675d2f7
commit 2337fe236e

View File

@@ -142,7 +142,7 @@ class MattermostMarkdownRenderer extends marked.Renderer {
if (outHref.startsWith(global.location.origin)) {
output += 'data-link="' + outHref.substring(global.location.origin.length) + '"';
} else {
output += 'href="' + outHref + '"';
output += 'href="' + outHref + '" target="_blank"';
}
if (title) {