Consider, that in 1876 when the Jesse James gang tried to rob the bank in Northfield, MN they were met with a hail of bullets from armed citizens and an armed citizen posse chased down and either killed or captured most of the gang members.
Same thing happened to the Dalton Gang in Coffeyville, Kansas.
They were wiped out by armed citizens.
Consider that was only a dozen or so years after the end of the Civil War, and there were probably plenty of veterans and young men trained in use of firearms by veterans of that conflict involved in the episode you describe.
The “wild” West wasn’t very wild, really, especially when compared to a modern urban ghetto. I maintain the above is one of the key reasons why.