The former UNC physics professor convicted of drug-smuggling will receive back-pay for time he spent in an Argentine prison.

The state Court of Appeals ruled Tuesday that UNC violated it policies when it put former physics professor Paul Frampton on unpaid leave following his arrest.

In January of 2012, authorities arrested Frampton in an Argentine airport with two kilograms of cocaine in his suitcase. The Argentine court found him guilty of drug-smuggling and sentenced him to nearly five years in prison. Frampton has maintained his innocence in the ordeal, saying he was duped into carrying the drugs by a Czech bikini model he met online.

The Court of Appeals said Tuesday that despite the circumstances, UNC cannot force a faculty member onto unpaid leave, and that the university could have resorted to disciplinary action against Frampton instead.

Superior Court Judge Allen Baddour will determine how much Frampton will receive in back-pay. Frampton spent more than two years on unpaid leave in an Argentine prison before UNC Chancellor Carol Folt fired him in 2014.

The university says it’s considering its legal options.