public IActionResult List() { if (!_repository.Any()) { return(View("Empty")); } var authors = _repository.GetAllWithBooks(); return(View(authors)); }
public IActionResult List() { if (!Admin.logged) { return(RedirectToAction("Login", "Admin", 0)); } if (!_repository.Any()) { return(View("Empty")); } var authors = _repository.GetAllWithBooks(); return(View(authors)); }
public bool Any(string authorId) { return(_authorRepository.Any(authorId)); }