mirror of
https://github.com/whitechi73/OpenShamrock.git
synced 2024-08-14 13:12:17 +08:00
Shamrock
: fix guild refresh error
This commit is contained in:
parent
b10b10d4a2
commit
48e4648110
@ -20,11 +20,15 @@ internal object GetGuildList : IActionHandler() {
|
||||
}
|
||||
|
||||
operator fun invoke(refresh: Boolean = true, echo: JsonElement = EmptyJsonString): String {
|
||||
PlatformUtils.requireMinQQVersion(version = PlatformUtils.QQ_9_0_8_VER)
|
||||
|
||||
val kernelGProService = NTServiceFetcher.kernelService.wrapperSession.guildService
|
||||
if (refresh) {
|
||||
kernelGProService.refreshGuildList(true)
|
||||
kernelGProService.guildListFromCache.forEach {
|
||||
kernelGProService.refreshGuildInfo(it.guildId, true, 1)
|
||||
}
|
||||
}
|
||||
PlatformUtils.requireMinQQVersion(version = PlatformUtils.QQ_9_0_8_VER)
|
||||
val result = arrayListOf<GuildInfo>()
|
||||
kernelGProService.guildListFromCache.forEach {
|
||||
if (it.result != 0) return@forEach
|
||||
|
Loading…
x
Reference in New Issue
Block a user