Răsfoiți Sursa

Some more fixes to remove all the special chars (#47)

Chris Black 8 ani în urmă
părinte
comite
bff7a39c3a
1 a modificat fișierele cu 2 adăugiri și 1 ștergeri
  1. 2 1
      sms/resources/install/scripts/app/sms/index.lua

+ 2 - 1
sms/resources/install/scripts/app/sms/index.lua

@@ -109,10 +109,11 @@ end
 	elseif direction == "outbound" then
 	elseif direction == "outbound" then
 		if (argv[3] ~= nil) then
 		if (argv[3] ~= nil) then
 			to_user = argv[3];
 			to_user = argv[3];
-			to_user = to_user:gsub("%sip%3A%40","");
+			to_user = to_user:gsub("^+?sip%%3A%%40","");
 			to = string.match(to_user,'%d+');
 			to = string.match(to_user,'%d+');
 		else 
 		else 
 			to = message:getHeader("to_user");
 			to = message:getHeader("to_user");
+			to = to:gsub("^+?sip%%3A%%40","");
 		end
 		end
 		if (argv[3] ~= nil) then
 		if (argv[3] ~= nil) then
 			domain_name = string.match(to_user,'%@+(.+)');
 			domain_name = string.match(to_user,'%@+(.+)');