Updated

A pit bull took a literal bite out of crime in Chicago on Friday when the dog's owner unleashed the canine on an armed man trying to rob someone in a gated community, officials said.

Marshon Hannah, 18, was charged with armed robbery and denied bail by a judge Sunday, the Chicago Tribune reported. The high school senior was dressed in blue scrubs and had a bandage on his right forearm.

Hannah is accused of trying to rob a 47-year-old man Friday in the Back of the Yards neighborhood of Chicago. Hannah allegedly pulled out a small black handgun and took a set of keys from the man and demanded property.

The man began moving slowly toward the backyard of a house where two friends were standing, and one of those men, watching the robbery unfold, unleashed the pit bull, telling the dog to attack Hannah, officials said. Hannah allegedly pulled the trigger several times, but the gun reportedly didn't fire.

The 18-year-old was still attempting to take a shot when the dog bit him, The Chicago Tribune reported. Hannah allegedly chucked the gun while he tried to flee from the group.

The three men reportedly caught up to Hannah, however, and held him down until police arrived. Officers said they found a .38-caliber revolver near the scene.

At the time of the arrest, Hannah was on probation for a juvenile armed robbery conviction. He also faces gun charges from a previous arrest.

Hannah is expected in court Friday.