public async Task <ServiceResponse <Task> > DeletePost(int postId) { ServiceResponse <Task> response = new ServiceResponse <Task>(); try { var post = await FindPostByIdAsync(postId); _context.Remove(post); await _context.SaveChangesAsync(); } catch (Exception ex) { response.Success = false; response.Message = ex.Message; } return(response); }