public async Task <IEnumerable <AirportType> > GetDestinations([Parent] AirlineType airline)
 {
     return(await Task.WhenAll(
                (await _dataStore.FetchRoutesByAirlineAsync(airline.Id))
                .Select(route => route.DestinationAirportId)
                .Distinct()
                .Select(async airportId =>
     {
         var airport = await _dataStore.GetAirportByIdAsync(airportId);
         return _mapper.Map <AirportType>(airport);
     })
                ));
 }
        public async Task <IEnumerable <RouteType> > GetRoutes([Parent] AirlineType airline)
        {
            var routes = await _dataStore.FetchRoutesByAirlineAsync(airline.Id);

            return(_mapper.Map <IEnumerable <RouteType> >(routes));
        }
        public async Task <CountryType> GetOrigin([Parent] AirlineType airline)
        {
            var countries = await _dataStore.FetchAllCountriesAsync();

            return(_mapper.Map <CountryType>(countries.FirstOrDefault(c => c.Name == airline.Country)));
        }