diff --git a/mirai-core/src/commonMain/kotlin/network/ContactListCache.kt b/mirai-core/src/commonMain/kotlin/network/ContactListCache.kt index 20b75ee21..a86265881 100644 --- a/mirai-core/src/commonMain/kotlin/network/ContactListCache.kt +++ b/mirai-core/src/commonMain/kotlin/network/ContactListCache.kt @@ -70,7 +70,7 @@ internal class GroupMemberListCaches( } private val changedGroups: MutableCollection = ConcurrentLinkedQueue() - private val groupListSaver by lazy { + private val groupListSaver: ScheduledJob by lazy { ScheduledJob(bot.coroutineContext, bot.configuration.contactListCache.saveIntervalMillis.milliseconds) { runBIO { saveGroupCaches() } } @@ -90,7 +90,7 @@ internal class GroupMemberListCaches( return ret } - private val cacheDir by lazy { bot.configuration.groupCacheDir() } + private val cacheDir: File by lazy { bot.configuration.groupCacheDir() } private fun resolveCacheFile(groupCode: Long): File { cacheDir.mkdirs()