Former Pakistan's Prime Minister Imran Khan has apologised for criticising a magistrate, his lawyer said on Thursday.
Khan, an international cricket star turned politician, was ousted through a no-confidence vote in April.
On Thursday he appeared at the Islamabad High Court, where he risked being indicted for contempt of court if he failed to apologise for his comments that followed the detention of a close aide.
His lawyer Faisal Chaudhry said; "Everybody should respect the court and that's what he's shown today.
"If he has crossed some red line, he apologizes for that."
Khan's lawyers said the case still remained technically active and that he would submit a formal "affidavit of apology."