Browse Source

Fixing NPE in getLengthOfNationalDestinationCode reported in issue 73

pull/567/head
Lara Scheidegger 14 years ago
committed by Mihaela Rosca
parent
commit
0b47ddf10a
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      java/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java

+ 1
- 1
java/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java View File

@ -923,7 +923,7 @@ public class PhoneNumberUtil {
return 0;
}
if (getRegionCodeForNumber(number).equals("AR") &&
if (getRegionCodeForCountryCode(number.getCountryCode()).equals("AR") &&
getNumberType(number) == PhoneNumberType.MOBILE) {
// Argentinian mobile numbers, when formatted in the international format, are in the form of
// +54 9 NDC XXXX.... As a result, we take the length of the third group (NDC) and add 1 for


Loading…
Cancel
Save