Fix possible NullPointerException in apps context menu

This commit is contained in:
emanuele-f 2023-04-23 19:53:04 +02:00
parent 88a9c747fd
commit c98740c830

View File

@ -238,6 +238,9 @@ public class AppsFragment extends Fragment implements ConnectionsListener, MenuP
boolean whitelistChanged = false;
AppStats app = mAdapter.getSelectedItem();
if(app == null)
return super.onContextItemSelected(item);
if(id == R.id.block_app)
blocklist.addApp(app.getUid());
else if(id == R.id.unblock_app_permanently)