Beispiel #1
0
        public async Task <IActionResult> GetByPostId(Guid id)
        {
            try
            {
                var post = await _postImageServices.GetPostImagesByPostIdAsync(id);

                return(Ok(post));
            }
            catch (Exception e)
            {
                _logger.LogError(e, e.Message);
                return(BadRequest());
            }
        }
Beispiel #2
0
 public async Task <IList <PostImageDto> > GetOriginalPostImagesAsync(Guid postId)
 {
     CheckIfIdIsCorrectFormat(postId);
     return(await _postImageServices.GetPostImagesByPostIdAsync(postId));
 }