Updated

Ghana's supreme court has ruled that the seizure of an Argentinian warship that led to a weeks-long ordeal last year was "fundamentally and patently wrong," a copy of the decision said Friday.

The Libertad, a three-masted tall ship, was held for nearly three months in the port city Tema in a dispute between the Argentinian government and NML Capital, a subsidiary of New York-based Elliott Capital Management.

It was finally released in December after a decision from a United Nations court.

"The courts of Ghana are not to promote conditions leading to possible military conflict when they have judicial discretion to follow an alternative path," the supreme court wrote in its ruling.

"There should accordingly be no further seizures of military assets of sovereign states by Ghanaian courts."

However, the court also said the Libertad's departure before the supreme court ruled was improper.

"Judicial notice is taken of the fact that during the pendency of these proceedings, the ARA Fragata Libertad, the Argentinian warship, sailed from Ghana in breach of the high court orders without resistance from Ghanaian authorities."

NML had obtained judgements in American and British courts against Argentina over the country's 2002 bond default.

When the Libertad arrived in October in Ghana on a goodwill mission, NML's attorneys convinced a commercial court judge in the capital Accra to hold the ship till Argentina settled with its bondholders.

The move caused a diplomatic standoff between Argentina and Ghana, one of west Africa's most stable and democratic countries.

Argentina went to the United Nations Tribunal on the Laws of the Sea, which ruled in December that the Libertad should be released.

Four days after the tribunal's ruling, Ghana's government petitioned the country's supreme court to overturn the lower court ruling.

The ship arrived back in Argentina early in January.