An Indonesian teen wrongfully jailed as an adult for people smuggling will have his conviction reviewed by a Western Australian court.
Ali Yasmin, also known as Ali Jasmin, was 14 when he was locked up in a maximum security prison from 2010 to 2012. The authorities had proof of his age, but let him spend two years in the adult jail. 
Mr Yasmin has spent the last year fighting to force the Commonwealth Attorney-General to refer his case to the Western Australia Court of Appeal so he can ask for his conviction to be quashed as he was a minor at the time.
Government policy stated that underage boat crew should be returned home and not prosecuted, including those whose age could not be determined.
If his conviction was quashed, he could potentially sue the government for wrongful imprisonment.
Attorney-General George Brandis has previously resisted making the referral, and Mr Yasmin launched court action to force the decision.
Mr Yasmin's lawyer, Sam Tierney, from Canberra law firm Ken Cush and Associates, confirmed his office had on Wednesday received correspondence that Mr Brandis had relented and referred the case to the WA court.
Mr Brandis used a Commonwealth instrument to direct the WA Court of Appeal to review the conviction.
"I, George Brandis, Attorney-General for the Commonwealth of Australia, having duly considered the petition, have decided to exercise my discretion to refer the whole case to the Court of Appeal as if it were an appeal by the petitioner against the petitioner's conviction."
Mr Yasmin came to Australia as a crew member aboard a boat carrying 55 Afghan nationals in   December 2009.
The Immigration Department believed he was about 14, but the Australian Federal Police instead estimated his age as 19. Mr Yasmin was tried as an adult and given a five-year jail sentence for people smuggling.
He celebrated his 16th birthday in jail, before being granted early release to return to his home island of Flores.
Earlier this year, the Federal Court found Mr Brandis had a duty to help correct a miscarriage of justice.
Mr Brandis' decision means the federal court case is likely to be discontinued.