Declare type explicitly for IDE inference issue

This commit is contained in:
Him188 2021-04-08 13:15:24 +08:00
parent 344c54531d
commit 45c6adf956

View File

@ -70,7 +70,7 @@ internal class GroupMemberListCaches(
}
private val changedGroups: MutableCollection<Long> = 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()