X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/c02633d77cb05a5deb05440d77b12ccc5bc19b85..a91e9542b384905187890f161d4da5396996fcfd:/projects/stargazer/plugins/configuration/sgconfig/parser_tariffs.cpp diff --git a/projects/stargazer/plugins/configuration/sgconfig/parser_tariffs.cpp b/projects/stargazer/plugins/configuration/sgconfig/parser_tariffs.cpp index 3ed22113..e22c78fe 100644 --- a/projects/stargazer/plugins/configuration/sgconfig/parser_tariffs.cpp +++ b/projects/stargazer/plugins/configuration/sgconfig/parser_tariffs.cpp @@ -23,8 +23,8 @@ #include "stg/tariffs.h" #include "stg/users.h" -#include "stg/optional.h" +#include #include // snprintf #include @@ -57,7 +57,7 @@ std::string AOS2String(const A & array, size_t size, const F C::* field, F multi } template -bool str2res(const std::string& source, STG::Optional& dest, T divisor) +bool str2res(const std::string& source, std::optional& dest, T divisor) { T value = 0; if (str2x(source, value)) @@ -67,7 +67,7 @@ bool str2res(const std::string& source, STG::Optional& dest, T divisor) } template -bool String2AOS(const std::string & source, A & array, size_t size, STG::Optional C::* field, F divisor) +bool String2AOS(const std::string & source, A & array, size_t size, std::optional C::* field, F divisor) { size_t index = 0; std::string::size_type from = 0; @@ -314,7 +314,7 @@ int CHG_TARIFF::Start(void *, const char * el, const char ** attr) void CHG_TARIFF::CreateAnswer() { - if (!td.tariffConf.name.data().empty()) + if (!td.tariffConf.name.value().empty()) { auto tariffData = td.get({}); if (m_tariffs.Chg(tariffData, &m_currAdmin) == 0)