1
0
mirror of https://github.com/nerzhul/ocsms.git synced 2025-06-07 16:06:15 +00:00

Fix regex and then duplicate numbers into conversation

This commit is contained in:
Loic Blot 2014-11-05 11:11:22 +00:00
parent 66859a4940
commit e655024521

View File

@ -143,7 +143,7 @@ class SmsController extends Controller {
$msgCount += $this->smsMapper->countMessagesForPhoneNumber($this->userId, $fmtPN); $msgCount += $this->smsMapper->countMessagesForPhoneNumber($this->userId, $fmtPN);
$fmtPNCleaned = preg_replace("#[ ]|-|\(|\)]#","", $fmtPN); $fmtPNCleaned = preg_replace("#[ ]|[-]|[(]|[)]#","", $fmtPN);
if (!in_array($fmtPNCleaned, $cleanedPhones)) { if (!in_array($fmtPNCleaned, $cleanedPhones)) {
$phoneNumbers[] = $fmtPN; $phoneNumbers[] = $fmtPN;
$cleanedPhones[] = $fmtPNCleaned; $cleanedPhones[] = $fmtPNCleaned;