A former flight attendant with American Airlines says he was unfairly terminated from his job after failing a breathalyzer test, claiming that his ketogenic (keto) diet was responsible for the false positive.

Andre Riley, who had been hired at American Airlines in 2012, was terminated last year following a breathalyzer test administered after a Las Vegas-to-Charlotte flight.

"I wasn't drinking,” Riley told Fox 46, claiming that he only “changed [his] diet.”

SEE IT: MAN, 91, BECOMES INTERNET SENSATION AFTER WORKING OUT IN OVERALLS

Riley, however, had previously failed a company breathalyzer in 2013, in an incident that was determined to be related to drinking. The Department of Transportation has a policy that bars anyone who fails more than once from working aboard an aircraft “for any employer.”

"I don’t want to be punished and take consequences for something that I didn't do," Riley told Fox 46. (Fox 46 Charlotte)

"I don’t want to be punished and take consequences for something that I didn't do. That's like admitting to a crime or going to jail even though I didn't do it,” Riley told Fox 13.

CLICK HERE TO SIGN UP FOR OUR LIFESTYLE NEWSLETTER

Riley’s claims about the keto diet aren’t entirely unfounded. According to a doctor who spoke with Men’s Health in 2019, when the keto diet was gaining popularity, certain breathalyzer equipment may give false positives when used by people in ketosis. The confusion, he says, may lie in the difference between ethanol alcohol — released through the breath after drinking — and isopropyl alcohol, which is released through the breath when the liver breaks down fat.

Dr. Ryan Lowery, who specializes in ketogenic diets and runs Ketogenic.com, further claimed to Fox 46 that “some devices aren't able to differentiate between isopropyl and ethanol.”

FOLLOW US ON FACEBOOK FOR MORE FOX LIFESTYLE NEWS

In a statement shared with Fox News, Riley's lawyer, Charles Adkins, claimed that Riley was asked to submit to a breathalyzer following a flight from Las Vegas to Charlotte, N.C., at which point he blew a .0050 and a .0052. But according to Adkins, Riley's colleagues never observed any smell, or intoxicated behavior, from Riley during the previous four-hour-plus flight.

Riley's lawyer tells Fox News that Riley's co-workers did not observe any impairment or odor during the preceding four-hour flight. (iStock)

"For Andre to blow a 0.05 after a 4 hour and 15-minute flight, he would have had to have been stumbling drunk getting on the flight, or consumed mini bottles from the plane's alcohol stock without being noticed by other passengers and crew members, and which are accounted for by log," said Adkins.

Adkins said he believes Riley's keto diet, combined with the "dated" technology of the particular breathalyzer device used, was responsible for the false positive.

COUPLE DIAGNOSED WITH CORONAVIRUS FLEW ON DELTA, HAWAIIAN FLIGHTS

Riley added that he fears the same thing will keep happening to other employees on the ketogenic diet unless the airline changes its equipment.

“I want them to use a more accurate test if someone is giving you a reason why this could possibly happen,” he said.

Riley reportedly seeks to be reinstated as a flight attendant with American Airlines. The carrier has declined to comment on the case at this time.

CLICK HERE TO GET THE FOX NEWS APP

The keto diet, which encourages the body to go into ketosis, and burn fat in the absence of carbs, was initially designed to help people who suffer from seizure disorders, but has become a trendy weight-loss diet in recent years.

Fox News' Katherine Lam contributed to this report.