Exemplo n.º 1
0
        public async Task <IActionResult> AcceptInvitationAsync(UserInvitationDto userInvitationDto)
        {
            var userId = await _userCommandService.AcceptInvitationAsync(userInvitationDto);

            var user = await _userQueryService.GetUserByIdAsync(userId);

            await _channelCommandService.AddUserToDefaultChannelsAsync(userId, user.WorkspaceId);

            await _conversationCommandService.StartSelfConversationAsync(userId, user.WorkspaceId);

            return(Ok());
        }