Was it really going to go any other way? It is very occasionally that the judiciary makes a common sense decision against the establishment. In this particular case it would not surprise me to find the dice were loaded from the start.
Not only that, when it comes to legislation, it is put in place for a specific intent, every single time the actual wording is twisted to form whatever reasoning they need/want at the time followed by surprise that it was used in this way.
I highly suspect that in reality the laws are made with the alter-purpose in mind, and it is then twisted around to fit a more publicly palatable justification (terrorists/children seem like winners every time).