public async Task <ActionResult <Author> > GetAuthorByAuthorIdAsync(int authorId) { Author dbAuthor = await _repository.GetAuthorAsync(authorId); if (dbAuthor == null) { return(NotFound()); } return(Ok(_mapper.Map <Data.Models.Author>(dbAuthor))); }