From e7e79b592e7fc337937a78fd9a0ef611ca2b06a5 Mon Sep 17 00:00:00 2001 From: Loic Blot Date: Mon, 13 Oct 2014 17:41:24 +0200 Subject: [PATCH] Fix condition when there isn't any contact associated with phone number --- js/script.js | 2 +- templates/main.php | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/js/script.js b/js/script.js index 682c263..ebf733f 100644 --- a/js/script.js +++ b/js/script.js @@ -86,7 +86,7 @@ function fetchConversation(phoneNumber) { conversationBuf = formatConversation(jsondata)[1]; conversationBuf += '
'; - if (typeof jsondata['contactName'] == 'undefined') { + if (typeof jsondata['contactName'] == 'undefined' || jsondata['contactName'] == '') { $('#ocsms-phone-label').html(phoneNumberLabel); curContactName = phoneNumberLabel; $('#ocsms-phone-opt-number').html(''); diff --git a/templates/main.php b/templates/main.php index a0dfd9a..0fc806d 100644 --- a/templates/main.php +++ b/templates/main.php @@ -13,6 +13,7 @@
Please choose a conversation on the left menu