An Iowa man who went on a rampage outside an Applebee's was thwarted from entering the restaurant thanks to quick-thinking customers and staff.

Police said that Joel Moots, 23, went to an Applebee's in Clive on Tuesday night and began throwing rocks at cars in the parking lot. He allegedly threatened to stab the restaurant's managers, KCCI reported.

Customers and staff called 911. The managers locked the restaurant's doors, but Moots followed and began kicking and banging on the door, trying to break his way in. Customers and staff held the door shut to prevent Moots from entering the restaurant.

Moots struck the door so hard the glass cracked, KCCI reported.

Police arrested Moots, who was charged with assault with a dangerous weapon and criminal mischief.