X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/e9ae1f101b5418c0ba2e6c9d86b23c12f0140982..c59911ca3cd38cf4ab36d2cc62686f97395899f9:/libs/srvconf/parsers/chg_admin.cpp diff --git a/libs/srvconf/parsers/chg_admin.cpp b/libs/srvconf/parsers/chg_admin.cpp index 31fbd4a4..bb4d8682 100644 --- a/libs/srvconf/parsers/chg_admin.cpp +++ b/libs/srvconf/parsers/chg_admin.cpp @@ -30,11 +30,11 @@ using namespace STG; std::string ChgAdmin::serialize(const AdminConfOpt& conf, const std::string& /*encoding*/) { std::string params; - if (!conf.login.empty()) - params += " login=\"" + conf.login.data() + "\""; - if (!conf.password.empty()) - params += " password=\"" + conf.password.data() + "\""; - if (!conf.priv.empty()) - params += " priv=\"" + std::to_string(conf.priv.data().toInt()) + "\""; + if (conf.login) + params += " login=\"" + conf.login.value() + "\""; + if (conf.password) + params += " password=\"" + conf.password.value() + "\""; + if (conf.priv) + params += " priv=\"" + std::to_string(conf.priv.value().toInt()) + "\""; return params; }