Alot of the 19th America was run by gangs to help authorities and politicians crack down on petty thieves and the black market. It helped keep things streamlined.

Plus, politicians would often use gangs as coersion for votes from citizens.