I don’t think it was intended.
I think that when you’re bombing thousands of targets, a 0.1-1% targeting error rate leads to dozens of unintended collateral hits (and thousands of civilians dead) — and is among the many reasons wars are horrific.
They hit the correct target. It's that although they could have, they didn’t check to see if it was a school first.
What if someone tells you it's an elementary school and you ignore them?