public async Task <Topic> FindByIdAsync([Required] FindByIdParams parameters) { // Check if user is authenticated await _authentication.AuthenticateAsync(parameters.AuthToken); return(await _repository.Topics.FindAsync(parameters.TopicId)); }
public async Task <Comment> FindByIdAsync([Required] FindByIdParams parameters) { // Check if player is authenticated await _authentication.AuthenticateAsync(parameters.AuthToken); return(await _repository.Comments.FindAsync(parameters.CommentId)); }
public async Task <Question> FindByIdAsync([Required] FindByIdParams parameters) { // Check if user is authenticated await _authentication.AuthenticateAsync(parameters.AuthToken); // Returns the given id return(await _repository.Questions.FindAsync(parameters.QuestionId)); }