A few dozen American Airlines flights were not able to take off Tuesday night because of a glitch in the iPad app that pilots use on board.

"In some cases, the flight had to return to the gate to access a Wi-Fi connection to fix the issue. We apologize for the inconvenience to our customers. We are working to have them on the way to their destination as soon as possible," said the airline's spokesperson, Andrea Huguely, The Verge reported.

In 2012, American Airlines was the first airline that was allowed by the FAA to swap its flight bags for iPads. Flight bags are loaded with terminal charts and other reference materials that each pilot must have on board for every flight. With the invention of the iPad, the 35-lb flight bags were replaced, making things lighter and easier for the pilots. Also, the flight's plans can be easily transmitted to the iPad.

The switch from flight bags to iPads saves the airline at least 400,000 gallons of fuel every year. In estimation, the company has replaced 24 million pages of documents for 8,000 iPads.

Some of the passengers on the flight tweeted about their experience during the delay. Some had to board another airline to get to their destination, while others opted to drive, according to USA Today.

While it remains unclear as to what caused the glitch, the airline assured its passengers that it is working on the issue to prevent future problems.