Fix concurrency in tracker

This commit is contained in:
max-klaus 2021-01-14 17:27:47 +03:00
parent 1a82db982f
commit 583ab5deba

View file

@ -447,8 +447,10 @@ class MainActivity : AppCompatActivity(), TelegramListener, ActionButtonsListene
} }
private fun runOnUi(action: (() -> Unit)) { private fun runOnUi(action: (() -> Unit)) {
if (!paused) { runOnUiThread {
runOnUiThread(action) if (!paused) {
action()
}
} }
} }