A deputy at a Florida jail was arrested after he made an inmate drop to the ground and do pushups as punishment for throwing a cookie and then kicked the prisoner in the side when he stopped, the Pinellas County Sheriff's Office said.

The incident occurred in January when inmate Mario Christo and two other prisoners who were assigned to a work crew in the county jail's kitchen were emptying trash into a dumpster. It wasn't reported to the sheriff's Internal Affairs division until last week when Christo was released on April 16.

Christo told officers that he was putting trash into a dumpster when he tossed a cookie to a bird. Deputy James Moran, 57, questioned Christo about throwing the cookie and punished him by telling him to do 50 pushups.

A detention deputy was arrested and terminated for battering an inmate at the Pinellas County Jail on Jan. 11, 2019 in pinellas, Florida. Pinellas County Sheriff's Office

The incident was caught on surveillance camera, and it shows Christo do roughly half of the ordered number of pushups before he gets tired and stops. Moran is seen in the video walking up to Christo and kicking him once in the side.

Pinellas County Sheriff Bob Gualtieri said at a news conference Tuesday that Christo told Internal Affairs that he believes Moran broke his rib when he kicked him but he did not immediately report the assault for fear of retribution.

"We have an absolute responsibility to these inmates," Gualtieri said, calling what Moran did "one of the stupidest things I've ever seen."

Christo was originally arrested by the St. Petersburg Police Department in July and charged with disorderly conduct, resisting an officer without violence and resisting an officer with violence. He was sentenced in October and was serving a 364-day sentence when the incident occurred. He was released in April for time served.

Moran, who has been with the department for about six years, was arrested Tuesday at the Sheriff's Administration Building and charged with one count of misdemeanor battery. He was taken to the Pinellas County Jail, the same facility where the incident occurred, and later released.

Moran was fired the same day.

Gualtieri said the deputy told Internal Affairs investigators that he had made inmates do pushups as punishment in the past.

"We don't treat people this way, we don't treat inmates this way," the sheriff said. "It's so contrary to what we do and the obligation we have."