Keep cleanup

This commit is contained in:
M66B
2019-08-03 15:36:51 +02:00
parent 07d0b30816
commit 952d93bf17
4 changed files with 29 additions and 29 deletions

View File

@@ -26,8 +26,6 @@ import android.content.SharedPreferences;
import androidx.preference.PreferenceManager;
import static android.os.Process.THREAD_PRIORITY_BACKGROUND;
public class ReceiverAutoStart extends BroadcastReceiver {
@Override
public void onReceive(final Context context, Intent intent) {
@@ -40,19 +38,7 @@ public class ReceiverAutoStart extends BroadcastReceiver {
ServiceSynchronize.boot(context);
ServiceSend.boot(context);
Thread cleanup = new Thread(new Runnable() {
@Override
public void run() {
try {
WorkerCleanup.cleanup(context, true);
} catch (Throwable ex) {
Log.e(ex);
}
}
});
cleanup.setPriority(THREAD_PRIORITY_BACKGROUND);
cleanup.start();
WorkerCleanup.queueOnce(context);
}
}
}