Like one who takes a dog by the ears is a passer-by who meddles in a quarrel not his own.
Proverbs 26:17 TLV
If nobody is in serious danger, mind your own business. You're more likely to get hurt yourself than to solve any real problems by intervening in the quarrels of strangers. Of course, if the dog is about to attack someone, then stop it if you can. Just make sure you are prepared for whatever comes next.