Exemplo n.º 1
0
        public async Task <IActionResult> DeleteCommentConfirmed(long id)
        {
            var comment = await _postRepository.GetPostCommentByIdAsync(id);

            var postId = comment.Post.Id;
            await _postRepository.DeleteCommentAsync(comment);

            return(RedirectToAction(nameof(Details), new { id = comment.Post.Id }));
        }