Workaround Android 9 Pie bug

This commit is contained in:
M66B 2018-10-13 10:48:55 +00:00
parent 8efdee1e8a
commit 947aa9d7a9
1 changed files with 4 additions and 0 deletions

View File

@ -1940,6 +1940,10 @@ public class ServiceSynchronize extends LifecycleService {
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(ServiceSynchronize.this);
if (!prefs.getBoolean("enabled", true)) {
EntityLog.log(ServiceSynchronize.this, "Not enabled, halt");
try {
Thread.sleep(3000);
} catch (InterruptedException ignored) {
}
stopSelf();
return;
}