diff --git a/build.gradle.kts b/build.gradle.kts index 10ffe91..d4769b9 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -7,7 +7,7 @@ plugins { } group = "xyz.cssxsh" -version = "1.4.6" +version = "1.4.7" mavenCentralPublish { useCentralS01() diff --git a/src/main/kotlin/xyz/cssxsh/mirai/plugin/WeiboHelperPlugin.kt b/src/main/kotlin/xyz/cssxsh/mirai/plugin/WeiboHelperPlugin.kt index 02630d1..c53978f 100644 --- a/src/main/kotlin/xyz/cssxsh/mirai/plugin/WeiboHelperPlugin.kt +++ b/src/main/kotlin/xyz/cssxsh/mirai/plugin/WeiboHelperPlugin.kt @@ -11,7 +11,7 @@ import xyz.cssxsh.mirai.plugin.command.* import xyz.cssxsh.mirai.plugin.data.* object WeiboHelperPlugin : KotlinPlugin( - JvmPluginDescription("xyz.cssxsh.mirai.plugin.weibo-helper", "1.4.6") { + JvmPluginDescription("xyz.cssxsh.mirai.plugin.weibo-helper", "1.4.7") { name("weibo-helper") author("cssxsh") } @@ -40,10 +40,10 @@ object WeiboHelperPlugin : KotlinPlugin( WeiboListener.start() globalEventChannel().subscribeOnce { - clear = this@WeiboHelperPlugin.launch { + clear = this@WeiboHelperPlugin.launch(Dispatchers.IO) { clear() } - restore = this@WeiboHelperPlugin.launch { + restore = this@WeiboHelperPlugin.launch(Dispatchers.IO) { restore() } diff --git a/src/main/kotlin/xyz/cssxsh/mirai/plugin/WeiboUtils.kt b/src/main/kotlin/xyz/cssxsh/mirai/plugin/WeiboUtils.kt index 9721b41..952b085 100644 --- a/src/main/kotlin/xyz/cssxsh/mirai/plugin/WeiboUtils.kt +++ b/src/main/kotlin/xyz/cssxsh/mirai/plugin/WeiboUtils.kt @@ -474,8 +474,8 @@ internal suspend fun restore(interval: Long = 3600_000) = supervisorScope { logger.info { "WEIBO登陆状态已刷新 $result" } continue } catch (throwable: SerializationException) { - logger.warning({ "构建WEIBO RESTORE 序列化时失败, $throwable" }, throwable) - sendLoginMessage("构建WEIBO RESTORE 任务序列化时失败, $throwable") + logger.warning({ "WEIBO RESTORE 任务序列化时失败, $throwable" }, throwable) + sendLoginMessage("WEIBO RESTORE 任务序列化时失败, $throwable") } catch (cause: Throwable) { logger.warning({ "WEIBO登陆状态失效,需要重新登陆, $cause" }, cause) sendLoginMessage("WEIBO登陆状态失效,需要重新登陆 /wlogin $cause")