Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 58e8a224 authored by Tyler Gunn's avatar Tyler Gunn Committed by android-build-merger
Browse files

Merge "Ensure null/empty phone number does not crash international number check." into oc-dev

am: 0f542b48

Change-Id: I6b534dbb9253ad66c850c8d55a8e4b0b619ac64e
parents 55302e2f 0f542b48
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -1449,6 +1449,11 @@ public class PhoneNumberUtils
     * @hide
     */
    public static boolean isInternationalNumber(String phoneNumber, String defaultCountryIso) {
        // If no phone number is provided, it can't be international.
        if (TextUtils.isEmpty(phoneNumber)) {
            return false;
        }

        // If it starts with # or * its not international.
        if (phoneNumber.startsWith("#") || phoneNumber.startsWith("*")) {
            return false;