use a background thread for scheduling things after boot

This commit is contained in:
tibbi
2018-03-30 10:50:26 +02:00
parent 913ec2b1c3
commit 134fd58c1a

View File

@@ -9,11 +9,13 @@ import com.simplemobiletools.calendar.extensions.scheduleAllEvents
class BootCompletedReceiver : BroadcastReceiver() { class BootCompletedReceiver : BroadcastReceiver() {
override fun onReceive(context: Context, arg1: Intent) { override fun onReceive(context: Context, intent: Intent) {
Thread {
context.apply { context.apply {
scheduleAllEvents() scheduleAllEvents()
notifyRunningEvents() notifyRunningEvents()
recheckCalDAVCalendars {} recheckCalDAVCalendars {}
} }
}.start()
} }
} }