Training and keeping control of their dogs. Like any breed, pit bulls have needs in order to be happy and well-adjusted dogs. Relevant here is that, just like any strong dog with the possible exception of some of the gentle giants, they need extra discipline and a firmer touch in training.
A properly trained and socialised pit bull that’s treated well will not attack people or other dogs, whereas untrained and/or not properly socialised dogs of ANY breed are likely to develop problem behaviour, which can include aggression.