Fix for 37448
[apps/osp/Call.git] / src / CallApp.cpp
index 81832ed..678d5ba 100644 (file)
@@ -516,16 +516,12 @@ CallApp::CheckNumberIsValid(String phoneNumber)
 {
        //Pattern to compare all characters except 0-9 * # P ; , +
        String phoneNumberPattern(L"[^0-9*#P,p+;]");
-       String phoneNumberEndingWithHash(L"#$");
-       RegularExpression checkPhoneNumber,checkHash;
+       RegularExpression checkPhoneNumber;
        checkPhoneNumber.Construct(phoneNumberPattern);
-       checkHash.Construct(phoneNumberEndingWithHash);
        //If there is any character other than these listed above then display invalid number
        bool resultMatch = checkPhoneNumber.Match(phoneNumber,false);
        //return false for patterns other than 0-9 * # P ; , +
-       bool endsWithHash = checkHash.Match(phoneNumber,false);
-       //returns false for any numbers that end with Hash
-       if(resultMatch == true || endsWithHash == true)
+       if(resultMatch == true)
        {
                //return phone number is invalid
                return false;