When a woman was caught shoplifting eggs over the weekend in Tarrant, Alabama, a police officer responded not with a court date but a carton of eggs.

CBS affiliate WIAT-TV reports that Officer William Stacy was called to the local Dollar General store on Saturday when the woman was caught trying to steal a dozen eggs.

Stacy recognized the woman because he had responded to a previous call to her house and had seen her difficult living conditions, WIAT reported.

When the store agreed not to press charges, Stacy decided to pay for the eggs.

Get Breaking News Delivered to Your Inbox

"She tried to give me all the money she had," Stacy said. "It was about $1.25. I told her the best way to pay me back was to never do something like that again."

A customer recorded the incident, which showed the officer hugging the woman in the store's parking lot. By Monday night, WIAT reported that the video had more than 265,000 views on Facebook.

"My phone was blowing up with notifications and texts," Stacy told the station.

Tarrant Police Chief Dennis Reno said he was he was gratified by the officer's gesture.

"I was pleasantly surprised that something good came out of me getting a phone call on a Sunday, instead of something bad," Reno said.