Mario rarely barks now, and I actually discourage barking because he is a service dog. They are to be almost completely silent when out. No whining, barking or growling when out as a service dog.
We have a big dog outside who has run of our yard who handles security. When the big dog barks, Mario used to bark too, I would tell him firmly but gently "stand down, let Bailey handle it". Now Mario hardly ever barks inside the house, but he still runs like crazy to look out the picture window to see what Bailey is barking at

.
The only times Mario does bark now is if one of us goes into kiddos room at night. Then he barks just a bit when the door handle is jiggled, and I do not discourage that since it rarely is much (stops when we say his name) nor does it usually wake up kiddo.