A Fairfield man was sentenced to three years in prison after pleading guilty to two felony charges of burglary.

Zachariah L. Kandler, 31, was arrested on Oct. 3 after turning himself in to the Blaine County Sheriff’s Office following a burglary that he committed on Oct. 2.

According to a probable-cause affidavit written by Sheriff’s Deputy Steven Hansen, law enforcement was dispatched to a home on Broadford Highlands Lane in Hailey on Oct. 2 for an unlawful entry in progress. Once on scene, officers found no one in the home and nothing was found missing, but the owner of the house allegedly had surveillance footage of the man who had entered the residence—Kandler—because he had done some landscaping work at the residence in the past.

After turning himself in, Kandler admitted to police that he had broken into another residence as well. After taking them to the residence, Kandler was arrested for two counts of felony burglary and pleaded guilty to those charges on Jan. 22 in exchange for two additional charges, another of felony burglary and a misdemeanor petit-theft charge, being dismissed by the prosecution.

During Kandler’s sentencing hearing on Monday, 5th District Judge Ned Williamson called the case “tragic,” noting Kandler’s brother’s suicide in 2009 at the county jail.

According to the affidavit, Kandler told police that he had developed an addiction to pills and had entered several unlocked homes in Ketchum and Hailey in the hope of finding pain pills. Williamson said during the sentencing hearing that Kandler told authorities that the addiction developed following a football injury when he was given opiates for pain.

Because of Kandler’s previous criminal convictions, including a felony burglary conviction in 2015 for which he was sentenced to a retained jurisdiction and now faces a misdemeanor probation violation, Williamson said his hands were tied in this case and ultimately sentenced Kandler to a determinate sentence of three years, with three years indeterminate.

“I think you’re a good person from what I can tell,” Williamson said, “but this behavior needs to stop.”