From f44467a2b531f77bc031269b965c86643549faba Mon Sep 17 00:00:00 2001 From: emaktech Date: Thu, 10 Jun 2021 03:10:32 -0400 Subject: [PATCH] Remove these as they break HTML emails. (#5969) * Remove these as they break HTML emails. * Remove quotes from Caller ID name and number. Same as following commits: https://github.com/fusionpbx/fusionpbx/commit/29c1d52533fd95ce0b995122471b9b283962bc3f https://github.com/fusionpbx/fusionpbx/commit/c93c20c4e10796e7b3e64c67565748e83f0a100c --- app/scripts/resources/scripts/app/hangup/index.lua | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/app/scripts/resources/scripts/app/hangup/index.lua b/app/scripts/resources/scripts/app/hangup/index.lua index 70410072af..54ca8d6d31 100644 --- a/app/scripts/resources/scripts/app/hangup/index.lua +++ b/app/scripts/resources/scripts/app/hangup/index.lua @@ -75,6 +75,12 @@ headers["X-FusionPBX-Domain-Name"] = domain_name; headers["X-FusionPBX-Call-UUID"] = uuid; headers["X-FusionPBX-Email-Type"] = 'missed'; + + --remove quotes from caller id name and number + caller_id_name = caller_id_name:gsub("'", "'"); + caller_id_name = caller_id_name:gsub([["]], """); + caller_id_number = caller_id_number:gsub("'", "'"); + caller_id_number = caller_id_number:gsub([["]], """); --prepare the subject subject = subject:gsub("${caller_id_name}", caller_id_name); @@ -94,8 +100,6 @@ body = body:gsub(" ", " "); body = body:gsub("\n", ""); body = body:gsub("\n", ""); - body = body:gsub("'", "'"); - body = body:gsub([["]], """); body = trim(body); --send the emails