public async Task <ActionResult <PostCommentDTO> > PostPostComment(PostCommentDTO newComment) { var comment = await _postComment.Create(newComment, UserClaimsGetters.GetUserId(User)); if (comment != null) { return(comment); } return(BadRequest()); }
public async Task <ActionResult <Comment> > CreateComment(Comment comment) { await _repo.Create(comment); return(Ok(comment)); }