A Quakertown man who delivered a fatal dose of heroin to a longtime friend in 2017 will spend up to 15 years behind bars.

Aaron Slimm, 32, was sentenced Thursday in Bucks County Court on a charge of drug delivery resulting in death, an increasingly popular criminal statute among local prosecutors fighting the opioid epidemic.

Slimm had been convicted in an October jury trial in the overdose death of Michael Eberle, 46, also of Quakertown.

“Two years ago I made a choice that I have regretted ever since that day,” Slimm said Thursday. “I can as

sure you that the person who made that choice is not the person standing in front of you today.”

Text messages between Slimm and Eberle recovered by investigators show that Slimm purchased heroin from a dealer in Philadelphia, and later gave some to Eberle, according to the county District Attorney’s Office.

Eberle was found unresponsive the next morning by his mother. He had several of the same bags of heroin, stamped with “Dream Chaser,” next to his body.

The first-degree felony Slimm was charged with, essentially homicide by heroin, has gained prominence in the counties surrounding Philadelphia in recent years. In Bucks County alone, prosecutors have leveled the charge more than two dozen times since 2013.

State law sets the statutory maximum penalty for the charge at 40 years, but Judge Gary B. Gilman said Thursday that he was “choosing hope” in handing down a lighter sentence to Slimm.