remove optional from auth_result

This commit is contained in:
Arthur Passos 2024-06-27 14:21:29 -03:00
parent 50da0cb732
commit 43a9194739
2 changed files with 2 additions and 2 deletions

View File

@ -521,7 +521,7 @@ std::optional<AuthResult> IAccessStorage::authenticateImpl(
{
if (auto user = tryRead<User>(*id))
{
AuthResult auth_result { .user_id = *id, .authentication_data = std::nullopt };
AuthResult auth_result { .user_id = *id };
if (!isAddressAllowed(*user, address))
throwAddressNotAllowed(address);

View File

@ -35,7 +35,7 @@ struct AuthResult
UUID user_id;
/// Session settings received from authentication server (if any)
SettingsChanges settings{};
std::optional<AuthenticationData> authentication_data;
AuthenticationData authentication_data {};
};
/// Contains entities, i.e. instances of classes derived from IAccessEntity.