public async Task <IActionResult> BindAsync(Guid userId, string connectionId) { var preferences = new BindConnectionToUserCommand { UserId = userId, ConnectionId = connectionId }; await _mediator.Send(preferences); return(NoContent()); }
public async Task <IActionResult> BindMeAsync(string connectionId) { var preferences = new BindConnectionToUserCommand { UserId = _contextAccessor.HttpContext.GetUserOrThrow().Id, ConnectionId = connectionId }; await _mediator.Send(preferences); return(NoContent()); }