From f67670dc0aaf99b04b895583d3c1ca16bd12565b Mon Sep 17 00:00:00 2001 From: Pierre HUBERT Date: Sun, 20 Jan 2019 19:40:29 +0100 Subject: [PATCH] Fixed little issue --- assets/js/common/utils.js | 2 +- assets/js/components/conversations/messageEditor.js | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/assets/js/common/utils.js b/assets/js/common/utils.js index 260d4915..f1e713f1 100644 --- a/assets/js/common/utils.js +++ b/assets/js/common/utils.js @@ -421,7 +421,7 @@ function checkString(value){ function removeHtmlTags(input){ //Check if input string is empty - if(input == null) + if(input == null || typeof input !== "string") return ""; //Prepare update diff --git a/assets/js/components/conversations/messageEditor.js b/assets/js/components/conversations/messageEditor.js index 2d5be7bc..3b729c0e 100644 --- a/assets/js/components/conversations/messageEditor.js +++ b/assets/js/components/conversations/messageEditor.js @@ -22,6 +22,9 @@ ComunicWeb.components.conversations.messageEditor = { function(content){ + if(!content) + return; + //Intend to update message content ComunicWeb.components.conversations.interface.UpdateSingleMessage( message.ID,