Fix incorrect plugin (option) values

This commit is contained in:
Raffson 2023-04-01 15:51:08 +02:00
parent 83eea8974b
commit 7c3d2367f2
No known key found for this signature in database
GPG Key ID: B0402B2C9B764D99

View File

@ -146,7 +146,7 @@ class LuaPlugin(PluginSettings):
@property
def enabled(self) -> bool:
return type(self.value) == bool and self.value
return type(self.get_value) == bool and self.get_value
@classmethod
def from_json(cls, name: str, path: Path) -> Optional[LuaPlugin]:
@ -172,7 +172,7 @@ class LuaPlugin(PluginSettings):
if self.options:
option_decls = []
for option in self.options:
value = str(option.value).lower()
value = str(option.get_value).lower()
name = option.identifier
option_decls.append(f" dcsRetribution.plugins.{name} = {value}")