public async Task <ActionResult <CountryDto[]> > GetCountryByName( string name = "", [FromQuery] bool includeCities = false, [FromQuery] bool includeTravelRestrictions = false) { try { var results = await _countryRepo.GetCountryByName ( name, includeCities, includeTravelRestrictions ); var mappedResult = _mapper.Map <CountryDto[]>(results); return(Ok(mappedResult)); } catch (Exception e) { return(this.StatusCode(StatusCodes.Status500InternalServerError, $"Database Failure: {e.Message}")); } }