diff options
author | Phil Hughes <me@iamphill.com> | 2017-06-26 18:15:51 +0300 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2017-06-29 12:01:12 +0300 |
commit | a136bd4edfd85aeefde115161ef807bb77656ad8 (patch) | |
tree | 1bf4be81eb9d443d4990ec79c8867e116c4a3cb8 /app | |
parent | 5bf817734ed92db8c2b750a7af406793d5e11b82 (diff) |
Fixed multi-line markdown in issue edit form
Closes #34318
Diffstat (limited to 'app')
-rw-r--r-- | app/assets/javascripts/lib/utils/text_utility.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/assets/javascripts/lib/utils/text_utility.js b/app/assets/javascripts/lib/utils/text_utility.js index 601d01e1be1..021f936a4fa 100644 --- a/app/assets/javascripts/lib/utils/text_utility.js +++ b/app/assets/javascripts/lib/utils/text_utility.js @@ -94,8 +94,8 @@ gl.text.insertText = function(textArea, text, tag, blockTag, selected, wrap) { startChar = !wrap && !currentLineEmpty && textArea.selectionStart > 0 ? '\n' : ''; - if (selectedSplit.length > 1 && (!wrap || (blockTag != null))) { - if (blockTag != null) { + if (selectedSplit.length > 1 && (!wrap || (blockTag != null && blockTag !== ''))) { + if (blockTag != null && blockTag !== '') { insertText = this.blockTagText(text, textArea, blockTag, selected); } else { insertText = selectedSplit.map(function(val) { |