The High Court in Nairobi has ordered the immediate release of firebrand opposition member Miguna Miguna.
Judge Luka Kimaru Tuesday gave the second ruling saying Mr Miguna remains free on the Ksh50,000 ($500) anticipatory bail he had granted on Friday.
Mr Miguna had been arrested last Friday in a dawn raid at his Nairobi house.
Police ignored the judge's order to release him ahead of his court appearance and kept him in an undisclosed location.
Inspector-General of Police Joseph Boinnet was ordered by court to either release Mr Miguna by close of business Monday, or appear in court Tuesday alongside his Director of Criminal Investigations George Kinoti to explain why they ignored an earlier order to release the activist. Both men however failed to appear before the courthouse on Tuesday but sent representatives who said their bosses were attending a national security meeting.
Mr Miguna who was also expected at the Nairobi court was not brought before it.
He was arraigned in a court in Kajiado County, about 75km south of Nairobi, on Tuesday morning charged with involvement in the January 30 mock inauguration of opposition leader Raila Odinga as the "people's president".
According to the charge sheet, Mr Miguna was accused of “being present and consenting to the administration of an oath to commit a capital offence, namely treason”.
The self-declared general of the opposition's National Resistance Movement (NRM) was also charged with being a member of a proscribed group. The government outlawed NRM last week for being a "criminal organisation".
His arrest followed that of Mr TJ Kajwang, a lawyer and MP, who was seized on Wednesday and was charged with treason and unlawful assembly.
The two men played prominent roles in the mock swearing-in, standing alongside Mr Odinga as he took an oath while clutching a Bible, Mr Miguna is his trademark kufi cap and Mr Kajwang in a judge's robe and wig.