Tunis: Tunisia said on Friday it was shutting its consulate in conflict-hit Libya as ten staffers abducted by an armed militia in Tripoli were heading home after a week in captivity.

The staff were seized when the gunmen burst into the consulate in the Libyan capital, in the latest attack targeting foreign citizens and diplomatic missions in the lawless nation.

Libya descended into chaos after a revolt unseated longtime dictator Muammar Gaddafi in 2011.

It now has rival governments and parliaments, as well as powerful militias battling for influence and a share of its oil wealth, including the Fajr Libya militia alliance that controls Tripoli.

Tunisian Foreign Minister Taieb Baccouche said the decision to shut the consulate was taken after the June 12 abduction of the staffers, although all ten of them had been freed and were on their way home.

“After this serious incident [kidnapping], we have decided to close the consulate in Tripoli,” Baccouche told reporters.

He was speaking at the L’Aouina military airport in Tunis, as he awaited the return of the former hostages.

“We will not reopen the consulate as long as protection for our civil servants is not guaranteed,” Baccouche said.

“When that protection becomes available, we will rethink” our options, said Baccouche, whose country has a consulate in Tripoli and another in the east of Libya.