The nine Singaporean armoured cars that the Hong Kong government seized and impounded for more than two months returned to the city state on Monday, ending an episode that seriously soured the Lion City’s relations with Beijing.

The Singapore Defence Ministry said in a statement: “The nine Singapore Armed Forces (SAF) Terrex infantry carrier vehicles and other equipment arrived in Singapore today at 1440hrs and will be transported to an SAF camp for post-training administration.”

The vehicles had been used for military drills in Taiwan.

Inside the Terrex military vehicle at the centre of Singapore-China storm

“The standard post-training administration for all vehicles and equipment include thorough serviceability checks and routine maintenance,” the statement read.

Defence Minister Ng Eng Hen said on Facebook that the “detailed checks” would take a few days.

“I am proud of how Singaporeans rallied together during this episode. Thank you for your support and encouragement,” he wrote.

Beijing reacted sharply after Hong Kong customs seized the shipment of vehicles on November 23 at the Kwai Tsing Terminals, while they were in transit back to Singapore from Taiwan.

China views Taiwan as a renegade province and has long discouraged Singapore from conducting military training there. In turn, land-short Singapore says it needs overseas military exercises in places like Taiwan to keep its forces battle-ready.

Hong Kong customs last week denied making the seizure at Beijing’s behest, saying its officers had suspected a breach of local laws on strategic commodities.

It released the vehicles on January 25, before their sea journey back to Singapore, but said it might initiate criminal proceedings against APL, the shipping company involved. It cleared Singapore authorities of any responsibility for the alleged breach.

‘Give me back my Terrex’: How Hong Kong saga inspired Singapore’s bloggers

Eugene Tan, a law professor at Singapore Management University, said the saga’s resolution showed “all parties did not lose sight of the big picture and the larger interests at stake”.

“The amicable resolution reflects a combination of observance of international law and Hong Kong domestic laws; quiet but principled diplomacy; and the strong foundation of bilateral ties between Singapore and Hong Kong, and between Singapore and China,” Tan said.

On social media, some Singaporeans cheered the return of the vehicles. The issue and the city state’s ties with China had become major talking points in the country in recent weeks.

“The [Terrexes] are back well before Chap Goh Meh which our government promised,” wrote Justin Ong on the Facebook page of state broadcaster Channel NewsAsia, referring to the celebration of the 15th day of the Lunar New Year, which falls on February 11. “It’s a great result for our country.”

“Should have lion dance in front of the Terrex in conjunction with Chinese New Year to dispel the bad luck under custody,” wrote another Facebook user.

Question marks remain, however, over how the saga will affect Singapore’s military ties with Taiwan, in place since 1975, under which thousands of Singaporean soldiers take part in unilateral live firing and manoeuvring exercises in the self-governing island’s southwest each year.

Singapore maintains a conscript-based military, and every able-bodied male citizen and resident over 18 years of age must do two years of military training. The wealthy island nation’s defence budget – at US$10.2 billion in 2016 – is the biggest in Southeast Asia, dwarfing that of its larger neighbours Malaysia and Indonesia.

Singapore likely to reduce defence ties with Taiwan over time, analysts say

With a land mass two-thirds that of Hong Kong’s, Singapore has turned to conducting exercises in a handful of friendly countries including Australia, India, Thailand, Brunei, the United States and Germany.

Watch: Singaporean military vehicles seizure explained

China has previously offered Singapore use of Hainan Island as an alternative training venue to Taiwan.

Singapore last year signed a US$1.7 billion deal with Australia to jointly develop military training areas and facilities in north Queensland.

The deal grants Singapore expanded military training access in Australia for 25 years, and allows it to increase the number of troops it rotates into the country from 6,000 to 14,000. The troops will also be allowed to stay for up to 18 weeks, up from 60 days.