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

Commit b25f123d authored by Shen Lin's avatar Shen Lin
Browse files

Add null check for mIntent in ZenRulePreference to avoid potential crash risk

Bug: 244120502

Test: manual test, ZenRuleScheduleHelperTest for unit test.
Change-Id: Ib7338253783bb09b84b629f2dd891292d82f28b2
parent d2212698
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -91,8 +91,10 @@ public class ZenRulePreference extends PrimarySwitchPreference {

    @Override
    public void onClick() {
        if (mIntent != null) {
            mContext.startActivity(mIntent);
        }
    }

    @Override
    public void setChecked(boolean checked) {