Don't unregister receiver unless it was registered.

This commit is contained in:
akwizgran
2017-11-22 11:37:58 +00:00
parent 748fa77d94
commit 9f3a63d8c4

View File

@@ -40,6 +40,7 @@ class DozeWatchdogImpl implements DozeWatchdog, Service {
@Override
public void stopService() throws ServiceException {
if (SDK_INT < 23) return;
appContext.unregisterReceiver(receiver);
}