Fungus feeds on dead tissue created by bacterial infection. You can treat for the fungus and still miss the culprit. Bacteria, like parasites, are present in all water systems. The general health of the fish and whether or not the fish has been stressed play a big role in whether the bacteria becomes a problem. Highly stressed fish become targets and will come down with a bacterial infection before a less-stressed, happier fish.
Bacteria can enter the fish by openings made by parasites or when a fish is injured.
Infected fish also spread disease to others. Overcrowded ponds are at high risk for Ulcer Disease and the dreaded Bacterial Gill Disease. There's nothing better to prevent bacterial complications than a clean, healthy pond environment. When you crowd too many people into a room someone will get sick, even if no one was ill before coming in. Everyone needs a little elbow room, even fish.