X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/090b0586b6561e4b3aa87d8365026aad119150f9..e7ccd2b51d13d9900fb3e841c13562e57448b279:/include/stg/user_conf.h diff --git a/include/stg/user_conf.h b/include/stg/user_conf.h index d5acb238..fe458211 100644 --- a/include/stg/user_conf.h +++ b/include/stg/user_conf.h @@ -104,8 +104,7 @@ struct USER_CONF_RES credit = uc.credit; nextTariff = uc.nextTariff; for (size_t i = 0; i < USERDATA_NUM; i++) userdata[i] = uc.userdata[i]; - services.resize(uc.services.size()); - for (size_t i = 0; i < uc.services.size(); ++i) services[i] = uc.services[i]; + services = uc.services; creditExpire = uc.creditExpire; ips = uc.ips; return *this; @@ -132,9 +131,7 @@ struct USER_CONF_RES { uc.userdata[i] = userdata[i].data(); } - uc.services.resize(services.size()); - for (size_t i = 0; i < services.size(); ++i) - uc.services[i] = services[i].data(); + uc.services = services.data(); uc.creditExpire = creditExpire.data(); uc.ips = ips.data(); return uc; @@ -157,7 +154,7 @@ struct USER_CONF_RES RESETABLE credit; RESETABLE nextTariff; std::vector > userdata; - std::vector > services; + RESETABLE > services; RESETABLE creditExpire; RESETABLE ips; };