using a helper function for ensuring background thread

This commit is contained in:
tibbi
2020-03-20 17:02:20 +01:00
parent c226f900e8
commit 1d4113545a
2 changed files with 4 additions and 3 deletions

View File

@ -17,6 +17,7 @@ import com.simplemobiletools.commons.extensions.*
import com.simplemobiletools.commons.helpers.LICENSE_NUMBER_PICKER
import com.simplemobiletools.commons.helpers.LICENSE_RTL
import com.simplemobiletools.commons.helpers.LICENSE_STETHO
import com.simplemobiletools.commons.helpers.ensureBackgroundThread
import com.simplemobiletools.commons.models.FAQItem
import kotlinx.android.synthetic.main.activity_main.*
@ -34,9 +35,9 @@ class MainActivity : SimpleActivity() {
initFragments()
if (getNextAlarm().isEmpty()) {
Thread {
ensureBackgroundThread {
rescheduleEnabledAlarms()
}.start()
}
}
}