I have a dog that due to continued interference from a neighbour and an electric fence does not like adults coming onto his property.
Off property he is fine. On property and you must first always come into the house and be "part of the family" for a short time for him to accept you. I know he is like this and put in precautions to keep both him and visitors safe.
However with children he is the opposite, he is not threatened by them at all and he will welcome them into the house and present them with his ball or frisbee to throw, he will cuddle up with them etc. They can be squealing, running, hugging etc and he laps it up, doesn't mean I don't supervise but to see the difference is astounding.
So he is the opposite to many many dogs. It's not unusual for dogs to be intolerant of young kids; many dogs are intolerant of puppies. Difference being most puppies are expert at dog body language, give off appropriate body language in response, have tougher skin than children and a layer of fur to protect them from snaps. Some dogs don't need a bad experience to feel uncomfortable around kids, kids body language, uncoordinated movements etc can be enough for some dogs.
My aunts dog didn't like kids, she would have her bed moved to the end of the verandah when we visited and we were told not to go near her. If we so much as looked at her she'd lift her lip and growl. Imagine my surprise when about 5 years later, when she was quite an old girl by then, she nudged my hand for a pat. In her eyes I'd grown up and I was now OK.
I know how much she scared me as a kid and I feel for any child that has been bitten.