He is the adult and she is the child.
He would be in the wrong 999 times out a 1000. No doubt about it.
But this is one of those 1 in 1000 case where it isnt so black and white.
This is a case about a confident and street smart 12 year old who can pass for 20.
She fooled everyone and she deceived him about her age. He is now suffering because of that deception.
This is why the judge did not punish him any further.
Some will say he deserves it for not being careful enough but i don't think it so easy to judge what happened unless you know all the facts of the case.