Antonio Ledezma, the incarcerated mayor of Venezuela's capital city of Caracas, was transferred from a prison to a hospital where he will undergo emergency surgery for a groin hernia.

As reported The Associated Press, Ledezma’s lawyer Omar Estacio announced that the jailed mayor was transferred early on Saturday after a Caracas court ordered his release due to medical reasons. Following the procedure Ledezma will be allowed to recuperate from his home.

Previous to his arrest Ledezma was treated for the same ailment.

The opposition leader was arrested by police during a February raid on his office, and he has been held at a military prison on charges of plotting a coup against Venezuela's socialist government.

As reported by the progressive site CommonDreams, some of the evidence the government claimed it had collected in the case against Ledezma were phone calls made by the mayor to a U.S. phone number, and a cache of weapons, including Molotov cocktails, explosives and gas masks, which were found in the office headquarters of the opposition political party.

The right-leaning mayor, who has been one of the staunchest critics of President Nicolas Maduro's administration, denies the allegation.

Maduro’s administration, noting the mayor’s association with Venezuela's conservative regimes of the 1980s and 1990s, has ridiculed Ledezma, calling him a "vampire."

As reported by The Associated Press, before his transfer to a medical facility for treatment, Ledezma was being held in a military prison on the outskirts of Caracas along with former Mayor Leopoldo Lopez, who was jailed in connection with his leadership of a protest movement that took hold of Venezuela in 2014.

Human rights groups across the globe, as well as critics of the Maduro administration, consider both Lopez and Ledezma to be Venezuela's highest-profile political prisoners.