The Maldives prosecutor general will appeal the former president's 13-year jail sentence after finding irregularities in the terrorism trial against him, the government said Friday. His lawyer said Mohamed Nasheed should be freed.

The prosecutor general found "procedural irregularities, including the violation of some fundamental rights," in the case, the statement from the government said.

Nasheed's lawyers had previously said that their client was not given a fair hearing, wasn't given enough time to prepare for his defense and his appeal was blocked by a delay in issuing case documents.

The trial sparked daily protests at home and drew widespread international condemnation.

Attorney's request

A lawyer for Nasheed said, regardless of the appeal, President Yameen Abdul Gayoom must use his authority to commute the sentence and free him.

"It remains our contention that the only way that justice can be served in this case is for President Yameen to commute the remainder of his sentence and enable him to be free," Jared Genser told reporters in Sri Lankan capital, Colombo.

Genser said he was denied a visa this month to visit the Maldives.

Nasheed was sentenced in March after a criminal court found him guilty of ordering the military to detain a senior judge when he was president three years ago. It said the detention was akin to abduction, which is a crime under the terrorism law.

The prosecutor general had earlier refused to file an appeal and the about-turn comes amid warming relations between the Gayoom administration and Nasheed-led Maldivian Democratic Party. The government statement did not say when the appeal would be filed.

Nasheed has since been transferred to house arrest and his lawmakers have voted with the government in Parliament to impeach the vice president whom Gayoom has replaced with a trusted minister. They also voted with the government in favor of a constitutional amendment allowing foreign freehold of land.