public IActionResult GetAll() { IEnumerable <Citizen> citizens = _citizenService.GetAll(); if (citizens == null) { return(NotFound()); } return(Ok(citizens)); }
public IEnumerable <CitizenDto> Get() { return(_citizenService.GetAll()); }
public async Task <ActionResult <IEnumerable <Citizen> > > GetAll() { var result = await _citizenService.GetAll(); return(Ok(result)); }