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

Commit 518a7dd4 authored by Hall Liu's avatar Hall Liu
Browse files

Fix potential NPE from 326226

Remove the .toString() so that null accounthandle doesn't throw an
exception

Change-Id: I594ee209207b4090b5ce3a6616bbbdb9da3c31fa
Test: none necessary
parent ded880cf
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -448,8 +448,7 @@ public class PhoneAccountRegistrar {
     */
    public boolean enablePhoneAccount(PhoneAccountHandle accountHandle, boolean isEnabled) {
        PhoneAccount account = getPhoneAccountUnchecked(accountHandle);
        Log.i(this, "Phone account %s %s.", accountHandle.toString(),
                isEnabled ? "enabled" : "disabled");
        Log.i(this, "Phone account %s %s.", accountHandle, isEnabled ? "enabled" : "disabled");
        if (account == null) {
            Log.w(this, "Could not find account to enable: " + accountHandle);
            return false;