From 54ea14323aae71e5b7ad75aae6f2f4064d96ea98 Mon Sep 17 00:00:00 2001 From: Robin Ward Date: Mon, 11 Aug 2014 12:45:55 -0400 Subject: [PATCH] FIX: Allow emoji at the beginning of a line without a paragraph break. --- plugins/emoji/assets/javascripts/emoji.js.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/emoji/assets/javascripts/emoji.js.erb b/plugins/emoji/assets/javascripts/emoji.js.erb index 2eeef638a..f1faf62e9 100644 --- a/plugins/emoji/assets/javascripts/emoji.js.erb +++ b/plugins/emoji/assets/javascripts/emoji.js.erb @@ -42,7 +42,7 @@ var lastToken = prev[prev.length-1]; if (lastToken && lastToken.charAt) { var lastChar = lastToken.charAt(lastToken.length-1); - if (lastChar !== ' ') return false; + if (lastChar !== ' ' && lastChar !== "\n") return false; } } return true;