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

Commit a8a61e07 authored by Danesh M's avatar Danesh M
Browse files

SmsUsageReceiver : Check if ur is null

Ensure a NPE doesn't occur by checking if the uri is null

Change-Id: Ie172caf616446afc6635839df41efef2f476f673
parent d31bfb58
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -231,6 +231,9 @@ public class SmsUsageMonitor {

        @Override
        public void onChange(boolean selfChange, Uri uri) {
            if (uri == null) {
                return;
            }
            if (uri.equals(Settings.Global.getUriFor(Settings.Global.SMS_SHORT_CODE_CONFIRMATION))) {
                mCheckEnabled.set(Settings.Global.getInt(mContext.getContentResolver(),
                        Settings.Global.SMS_SHORT_CODE_CONFIRMATION, 1) != 0);