Amer Khayyat, accused of planning to blow up an Etihad Airlines flight, released on bail in Beirut, his lawyer says.

The lawyer of an Australian-Lebanese dual citizen on trial in Beirut for an alleged plot to bring down a passenger plane says her client has been ordered to be released on bail by a Lebanese military court.

Joceline Adib al-Rai, Amer Khayyat’s lawyer, said on Saturday the court’s decision was delivered a day earlier. Prosecutors can still appeal his release.

Lebanese authorities have held Khayyat in detention since 2017, accusing him of planning to blow up an Etihad Airlines flight that was supposed to travel from Sydney to the United Arab Emirates (UAE).

It has been alleged that Khayyat attempted to smuggle an improvised explosive device onto the Abu Dhabi-bound flight but his luggage was rejected at a Sydney Airport check-in counter because it was too heavy.

Australian police said he was unaware that he was carrying a bomb, disguised as a meat grinder, in his luggage, as he tried to check in at the airport.

Amer’s brothers, Khaled Khayyat, 49, and Mahmoud Khayyat, 32, were later arrested in Sydney and charged with “preparing for, or planning, a terrorist attack”. They remain in custody in Sydney.

During his trial in May last year, Amer Khayyat rejected the charges and broke down in tears as he faced a Lebanese military court in Beirut, insisting he was innocent.

“I am a nightclub man, a drugs man,” he told the court. “I didn’t know anything.”

Another brother, Tareq Khayyat, an Islamic State of Iraq and the Levant (ISIL or ISIS) commander and Lebanese citizen, was arrested in Iraq in 2018, according to media reports.

Police in Australia had alleged that the explosives used to make the bomb were sent to Sydney by air cargo from Turkey as part of a plot “inspired and directed” by ISIL, which police said was among the most sophisticated ever attempted in Australia.

In February last year, Israel said it helped avert the plot to bring down the plane.

In a speech in Jerusalem, Israeli Prime Minister Benjamin Netanyahu credited his nation’s intelligence services with preventing “an unimaginable slaughter”.

Australia’s Home Affairs Minister Peter Dutton later confirmed that Israel was involved in uncovering the plot.

Speaking to local radio station 2GB, Dutton said the Etihad flight was “almost blown out of the sky”.

“[It] would have resulted in hundreds of people losing their lives, so we are very grateful for the assistance Israel provided in that matter,” Dutton added.