This commit is contained in:
2021-08-01 20:09:11 -05:00
parent b10f61a489
commit bb1d2c491c
6 changed files with 13 additions and 52 deletions

View File

@@ -34,11 +34,11 @@ namespace Gameboard.ShogiUI.Sockets.Managers
while (count < MaxTries)
{
count++;
var clientId = $"Guest-{Guid.NewGuid()}";
var isCreated = await repository.CreateGuestUser(clientId, webSessionId);
var userName = $"Guest-{Guid.NewGuid()}";
var isCreated = await repository.CreateUser(new User(userName, webSessionId));
if (isCreated)
{
return clientId;
return userName;
}
}
throw new OperationCanceledException($"Failed to create guest user after {count} tries.");