Don't throw exception if timer is already finished

This commit is contained in:
DBotThePony 2022-12-04 12:51:09 +07:00
parent 3e70cc2a60
commit 1f7b8a6858
Signed by: DBot
GPG Key ID: DCC23B5715498507

View File

@ -44,7 +44,7 @@ class TimerQueue {
}
fun execute() {
check(!finished) { "Already finished" }
if (finished) return
runnable.run()
finished = true
}