Police charged him with indecent assault, common assault and a breach of the extended supervision order he was subject to.
Because he had been convicted of indecent assault twice before, he was subject to the now repealed "three strikes" law, meaning the sentencing judge jailed him for the maximum of seven years for that offence.
When he was sentenced in May 2018, the judge noted the indecent assault was at the "bottom end" and would not have ordinarily attracted a prison sentence at all.
The Court of Appeal, however, upheld the seven-year sentence.
But the Appeal Court judges also said the seven-year sentence was "manifestly unjust", particularly as Fitzgerald's mental health issues meant he was unable to regulate his behaviour "in the manner our society expects".
Court records show that Fitzgerald had suffered from schizophrenia, with drug and alcohol abuse, from the age of 15.
He has a history of paranoid delusions and auditory and visual hallucinations, requiring ongoing care.
Before being sent to jail, he had been admitted to mental health facilities at least 13 times.
The Supreme Court upheld his conviction, but a majority of four judges allowed his appeal against his sentence and sent that back to the High Court.
On resentencing in 2021, a High Court judge observed that Fitzgerald had been detained "way too long" and imposed a sentence of six months imprisonment, meaning he was released immediately.
By this time, he had already spent 1789 days in prison—almost 1700 days longer than he would have been required to serve under his six-month sentence, for which he could have expected to be released after three months.
"It is beyond dispute that Mr Fitzgerald's sentence was not simply disproportionate, it was grossly so, in breach of one of his most fundamental rights," Justice Ellis said in her judgement.
She said the breach of Fitzgerald's rights deprived him of liberty for about 55 months.
"He is not a defendant who was always lawfully detained but whose successful sentence appeal means that he has spent two or three months longer in prison than he should have.
"Rather, he is a vulnerable person who was wrongly detained for a very considerable period because the decision to prosecute him for a stage three offence was made without any consideration of his (Bill of Rights Act) right."
She awarded Fitzgerald $450,000, plus interest calculated from a date to be confirmed.
The contentious three strikes law was repealed this year.