diff options
| -rw-r--r-- | src/web/app/common/scripts/text-compiler.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/web/app/common/scripts/text-compiler.js b/src/web/app/common/scripts/text-compiler.js index e08ef74417..62636939bf 100644 --- a/src/web/app/common/scripts/text-compiler.js +++ b/src/web/app/common/scripts/text-compiler.js @@ -1,8 +1,8 @@ const riot = require('riot'); -module.exports = function(tokens, canBreak, escape) { - if (canBreak == null) { - canBreak = true; +module.exports = function(tokens, shouldBreak, escape) { + if (shouldBreak == null) { + shouldBreak = true; } if (escape == null) { escape = true; @@ -17,10 +17,10 @@ module.exports = function(tokens, canBreak, escape) { return token.content .replace(/>/g, '>') .replace(/</g, '<') - .replace(/(\r\n|\n|\r)/g, canBreak ? '<br>' : ' '); + .replace(/(\r\n|\n|\r)/g, shouldBreak ? '<br>' : ' '); } else { return token.content - .replace(/(\r\n|\n|\r)/g, canBreak ? '<br>' : ' '); + .replace(/(\r\n|\n|\r)/g, shouldBreak ? '<br>' : ' '); } case 'bold': return '<strong>' + token.bold + '</strong>'; |