TEHRAN, Iran (AP) — Iran’s embattled president has backed down from a public dispute with his country’s judiciary.

Mahmoud Ahmadinejad says he will avoid political quarreling, focusing instead on alleviating pressures over Western sanctions.

Ahmadinejad’s retreat comes a day after Supreme Leader Ayatollah Ali Khamenei warned government officials and politicians against going public with disputes.

Khamenei’s harsh criticism was seen as a direct strike at Ahmadinejad, who publicly criticized Iran’s judiciary chief last week for rejecting his request to visit Evin prison, where an aide is being held.

Ahmadinejad made the pledge to end the dispute in a letter to Khamenei, posted on president.ir late Thursday.

Khamenei, who has the final say on all state matters, said provoking political differences in public ahead of presidential elections, scheduled for June 14 next year, is “treason.”

Copyright 2012 The Associated Press.