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

Commit aae05232 authored by Dmitri Plotnikov's avatar Dmitri Plotnikov Committed by Android (Google) Code Review
Browse files

Merge "Throws IllegalArgumentException if the country code is null."

parents aa6d3921 1e80299b
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -81,7 +81,7 @@ public class PhoneNumberFormattingTextWatcher implements TextWatcher {
     * may not take effect on this instance.
     */
    public PhoneNumberFormattingTextWatcher() {
        this (Locale.getDefault() != null ? Locale.getDefault().getCountry() : "US");
        this(Locale.getDefault().getCountry());
    }

    /**
@@ -93,6 +93,7 @@ public class PhoneNumberFormattingTextWatcher implements TextWatcher {
     * @hide
     */
    public PhoneNumberFormattingTextWatcher(String countryCode) {
        if (countryCode == null) throw new IllegalArgumentException();
        mFormatter = PhoneNumberUtil.getInstance().getAsYouTypeFormatter(countryCode);
    }