public void SaveAuthor(Author author) { var existingAuthor = _manager.AuthorRepository.GetByID(author.AuthorId); if (existingAuthor == null) { _manager.AuthorRepository.Insert(author); _manager.save(); } else { _manager.AuthorRepository.Update(author); } }
public void UpdateAuthor(Author authorToUpdate) { authorService.SaveAuthor(authorToUpdate); }