fix for EverySecondScheduler

This commit is contained in:
InsanusMokrassar 2020-06-03 21:39:52 +06:00
parent 686716e20f
commit 565aff4538
2 changed files with 4 additions and 2 deletions

View File

@ -13,6 +13,7 @@
* Kotlin `1.3.70` -> `1.3.72`
* Coroutines `1.3.5` -> `1.3.7`
* Klock `1.10.0` -> `1.11.3`
* `EverySecondScheduler` changed its building logic - now it is lazy with builder using
### 0.2.2

View File

@ -18,8 +18,9 @@ val AnyTimeScheduler: KronScheduler by lazy {
/**
* [KronScheduler.next] will always return [com.soywiz.klock.DateTime.now] + one second
*/
val EverySecondScheduler: KronScheduler
get() = AnyTimeScheduler
val EverySecondScheduler: KronScheduler by lazy {
buildSchedule { seconds { 0 every 1 } }
}
/**
* [KronScheduler.next] will always return [com.soywiz.klock.DateTime.now] + one minute