From 7670be4ca58a19d9d3f381097ef1c6ee9716e20c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Blin?= <sebastien.blin@savoirfairelinux.com> Date: Fri, 7 Jul 2023 14:49:06 -0400 Subject: [PATCH] account_config: fix defaultModerators serialization when unserialized, the default moderators is always empty Change-Id: Ie23af56bfcae7de2895ea242df10cc0f926b659e --- src/account_config.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/account_config.cpp b/src/account_config.cpp index b9f3d37107..5b2df46b48 100644 --- a/src/account_config.cpp +++ b/src/account_config.cpp @@ -75,7 +75,8 @@ AccountConfig::serializeDiff(YAML::Emitter& out, const AccountConfig& DEFAULT_CO SERIALIZE_CONFIG(USER_AGENT_KEY, customUserAgent); SERIALIZE_CONFIG(DISPLAY_NAME_KEY, displayName); SERIALIZE_CONFIG(UPNP_ENABLED_KEY, upnpEnabled); - SERIALIZE_CONFIG(DEFAULT_MODERATORS_KEY, defaultModerators); + out << YAML::Key << DEFAULT_MODERATORS_KEY << YAML::Value + << fmt::format(FMT_COMPILE("{}"), fmt::join(defaultModerators, "/"sv)); SERIALIZE_CONFIG(LOCAL_MODERATORS_ENABLED_KEY, localModeratorsEnabled); SERIALIZE_CONFIG(ALL_MODERATORS_ENABLED_KEY, allModeratorsEnabled); SERIALIZE_CONFIG(PROXY_PUSH_TOKEN_KEY, deviceKey); -- GitLab