mirror of
https://github.com/mamoe/mirai.git
synced 2025-01-27 00:20:19 +08:00
parent
321aa74a66
commit
df8b819d37
@ -73,7 +73,9 @@ internal open class MultiFilePluginDataStorageImpl(
|
|||||||
public override fun store(holder: PluginDataHolder, instance: PluginData) {
|
public override fun store(holder: PluginDataHolder, instance: PluginData) {
|
||||||
getPluginDataFile(holder, instance).writeText(
|
getPluginDataFile(holder, instance).writeText(
|
||||||
kotlin.runCatching {
|
kotlin.runCatching {
|
||||||
yaml.encodeToString(instance.updaterSerializer, Unit)
|
yaml.encodeToString(instance.updaterSerializer, Unit).also {
|
||||||
|
yaml.decodeAnyFromString(it) // test yaml
|
||||||
|
}
|
||||||
}.recoverCatching {
|
}.recoverCatching {
|
||||||
// Just use mainLogger for convenience.
|
// Just use mainLogger for convenience.
|
||||||
MiraiConsole.mainLogger.warning(
|
MiraiConsole.mainLogger.warning(
|
||||||
|
Loading…
Reference in New Issue
Block a user