config exclude

This commit is contained in:
Jörn-Michael Miehe 2023-09-07 21:11:16 +00:00
parent d05e3b94be
commit 2e0004bfcb

View file

@ -62,7 +62,12 @@ async def get_config() -> Config:
async def set_config(cfg: Config) -> None:
txt = tomli_w.dumps(cfg.model_dump())
txt = tomli_w.dumps(
cfg.model_dump(
exclude_defaults=True,
exclude_unset=True,
)
)
await dav_write_textfile_content(
path=SETTINGS.config_filename,