public async Task <CosmosPostDto> GetPostByIdAsync(string id) { var post = await _postRepository.GetByIdAsync(id); return(_mapper.Map <CosmosPostDto>(post)); }
public async Task DeletePostAsync(string id) { var post = await _postRepository.GetByIdAsync(id); await _postRepository.DeleteAsync(post); }