Рабочая сборка с третьей ручкой

This commit is contained in:
Антон
2025-09-27 19:22:09 +03:00
parent 8ede71fe48
commit 355d03aaac
3 changed files with 8 additions and 8 deletions
+3 -3
View File
@@ -37,7 +37,7 @@ public:
using namespace boost::beast;
using namespace std::string_literals;
auto body = req.body();
const auto body = req.body();
value req_json;
value response_body;
@@ -62,7 +62,7 @@ public:
return res;
}
std::optional<user> maybe_user = user_dao_->GetByLogin(login);
const std::optional<user> maybe_user = user_dao_->GetByLogin(login);
if (!maybe_user.has_value() || maybe_user.value().hashed_password != HashPassword(password))
{
@@ -75,7 +75,7 @@ public:
return res;
}
auto token = GenerateUUID();
const std::string token = GenerateUUID();
auth_dao_->Login(maybe_user.value().uuid, token);
http::response<ResponseType> res{http::status::ok, req.version()};