delete event types on a background thread

This commit is contained in:
tibbi 2018-03-27 21:55:27 +02:00
parent ee81883508
commit 8d1a2fabe0

View file

@ -62,11 +62,13 @@ class ManageEventTypesActivity : SimpleActivity(), DeleteEventTypesListener {
}
}
dbHelper.deleteEventTypes(eventTypes, deleteEvents) {
if (it == 0) {
toast(R.string.unknown_error_occurred)
Thread {
dbHelper.deleteEventTypes(eventTypes, deleteEvents) {
if (it == 0) {
toast(R.string.unknown_error_occurred)
}
}
}
}.start()
return true
}
}