X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/e9cb0683c0b33d8458c1d9b2558bbeb5d101e680..da9b6f95cc1927507f2aeddd079528c7368025a1:/projects/stargazer/plugins/configuration/sgconfig/parser_auth_by.cpp?ds=sidebyside
diff --git a/projects/stargazer/plugins/configuration/sgconfig/parser_auth_by.cpp b/projects/stargazer/plugins/configuration/sgconfig/parser_auth_by.cpp
index 54921571..21765e11 100644
--- a/projects/stargazer/plugins/configuration/sgconfig/parser_auth_by.cpp
+++ b/projects/stargazer/plugins/configuration/sgconfig/parser_auth_by.cpp
@@ -1,5 +1,8 @@
#include "parser_auth_by.h"
+#include "stg/users.h"
+#include "stg/user.h"
+
int PARSER_AUTH_BY::ParseStart(void * /*data*/, const char *el, const char **attr)
{
if (strcasecmp(el, "GetUserAuthBy") == 0)
@@ -28,19 +31,17 @@ return -1;
void PARSER_AUTH_BY::CreateAnswer()
{
-answerList->erase(answerList->begin(), answerList->end());
-
USER_PTR u;
if (users->FindByName(login, &u))
{
- answerList->push_back("");
+ answer = "";
return;
}
-std::string s = "";
+answer.clear();
+answer += "";
std::vector list(u->GetAuthorizers());
for (std::vector::const_iterator it = list.begin(); it != list.end(); ++it)
- s += "";
-s += "";
-answerList->push_back(s);
+ answer += "";
+answer += "";
}