Crew members are trained to handle emergencies, from medical issues to technical problems. In case of an emergency, pilots might divert the flight to the nearest airport, where passengers can receive assistance.