From ba5db45e7aba220aa9743d4f3fb4b41d5a698148 Mon Sep 17 00:00:00 2001 From: cel Date: Wed, 15 Feb 2017 16:41:54 -0800 Subject: Use \n instead of \r\n in message text --- lib/serve.js | 1 + 1 file changed, 1 insertion(+) (limited to 'lib') diff --git a/lib/serve.js b/lib/serve.js index 64f25f0..e1770a3 100644 --- a/lib/serve.js +++ b/lib/serve.js @@ -794,6 +794,7 @@ Serve.prototype.composer = function (opts, cb) { try { content = JSON.parse(data.text) } catch (err) { + data.text = String(data.text).replace(/\r\n/g, '\n') content = { type: 'post', text: data.text, -- cgit v1.2.3