SAN FRANCISCO (CBS SF) — A man kicked out of a drug treatment program for taking a cookie without asking chose to serve six months in county jail rather than return to the program, the San Francisco Public Defender’s Office said.

42-year-old Gregory Fields was remanded by a judge to six months in San Francisco County Jail after he said he would not restart at Harbor Lights, the program which he was kicked out of.

READ MORE: Slow Recovery Prompts Businesses to Rethink Their Future in Downtown San Francisco

Fields was first admitted into the Harbor Lights program in 2017 by San Francisco Drug Court while on probation for a vandalism charge. Fields, a former addict, successfully completed the 30-day detox and a 30-day blackout period in which he couldn’t contact anyone, including his mother, who he lived with in San Francisco.

After completing both phases, he regularly attended meetings and court.

After a Harbor Lights outing where the program prepared lunch for the homeless, Fields apparently returned to the site and ate a leftover cookie without permission. Harbor Lights asked him to leave the program afterward.

READ MORE: South Bay Restaurants Raise Money for Anti-Hate Efforts Supporting AAPI Community

Fields contacted his case worker, who convinced Harbor Lights to let him stay on one condition: he had to restart the program, including the 30-day blackout period. He went back to his family because he didn’t want to be shut out again, the SFPDO said.

To maintain his new found sobriety after being clean for three months, he then sought other outpatient treatment. He went to Drug Court group meetings run by San Francisco’s Department of Public Health, but was turned away.

After no other alternative options for Field were offered, his only alternative was to serve six months in county jail and he took that option.

SF Deputy Public Defender Dana Drusinsky reprimanded the Harbor Lights program and the court’s response to Fields’ situation.

MORE NEWS: San Jose State University President Says Ex-Trainer Improperly Touched Athletes

“If the court and providers were in fact focused on Mr. Fields’s recovery, they would not have locked him up for eating a cookie,” Drusinsky said.