Small children do not know how to act around a dog, want to pull on their tails or ears, hug them like a stuffed animal ... the little kid probably was staring the dog right in the face, at close range. Try that yourself, with even your own dog, and you might get growled at or even nipped yourself. I’m sorry the kid was bitten, but where was the supervision? The adults were to blame.
There are dogs nowdays that will put up with all of that. They are useless animals in my opinion. Any dog that will put up with all of that is a dog that is useless in every other metric. but that’s the way the people want their dogs nowdays...it seems.