Solomon Islands' dumped Attorney General Primo Afeau is to become a high court judge.
Mr Afeau has been removed from the post after he angered the prime minister, Manasseh Sogavare, by challenging the terms of reference he set for the commission of inquiry into the riots in Honiara in April.
Mr Sogavare announced that Mr Afeau would be leaving his job just before he left for the United Nations general assembly meeting in New York.
A government spokesman, Alfred Maesulia, says the prime minister felt they could no longer work together.
"He took the government to court and the prime minister felt he couldn't work with him. That is the main reason he is out of a job."
Mr Maesulia says making Mr Afeau a judge is not a demotion.
He says a new attorney general is yet to be named.