I don't think being out in public should ever be an excuse for not exercising discipline.
But I also think I should avoid shouting in public out of consideration for other people.
Funnily enough, I don't really feel the two have to be contradictory. Tbh I have never found shouting is such an essential part of discipline. It's more a relief to my feelings.
If I had to shout, then they know I don't embarrass easily, but in fact it's almost easier to make them obey without shouting. I have been practising the look assiduously for many years. That and the firm grip. And removal from situation.
I used to be a supply teacher in some pretty rough schools, where physical punishment was not an option and shouting only made you seem out of control. So I had already practised the look and the ominously quiet voice before dd was even born.