Fix #117: owning setting storage is not set after load

This commit is contained in:
Him188 2020-08-20 20:11:21 +08:00
parent f862f575d7
commit a6d98426e3

View File

@ -146,7 +146,7 @@ internal open class MultiFileSettingStorageImpl(
check(file.exists() && file.isFile && file.canRead()) { "${file.absolutePath} cannot be read" }
Yaml.default.decodeFromString(instance.updaterSerializer, file.readText())
instance
}
}.also { it.setStorage(this) }
protected open fun getSettingFile(holder: SettingHolder, clazz: KClass<*>): File = with(clazz) {
val name = findASerialName()