public async Task <ActionResult <FlightDTO> > GetFlight(int id) { var flightItem = await _flightRepository.GetFlight(id); if (flightItem != null) { return(Ok(_mapper.Map <FlightDTO>(flightItem))); } return(NotFound()); }
private void OnTimerEvent(int id) { FlightModel flight = _flightsRepository.GetFlight(id); _stationsManager.FlightTimeArrivedEvent(flight); }