OLATHE, Kan. (KAKE) - A Johnson County woman has been sentenced to three years of probation for the death of her 17-month-old son in a house fire earlier this year. 

Karlie Phelps, 28, pleaded guilty in August to involuntary manslaughter and child endangerment. KSHB reports she was sentenced Thursday to 18 years in prison, but a judge granted a defense motion for a dispositional departure and placed her on probation. She will be subject to the balance of her 18-year prison sentence if she violates probation. 

Phelps was charged in February after her son, Nicholas Ecker Jr., died in a fire at her home in Shawnee on Feb. 13. Phelps admitted to investigators that she left the child alone while she went to buy prescription pain medication and was not home at the time of the fire, according to court records.

The child’s father, Nicholas Adam Ecker, has been charged with first-degree murder and aggravated arson in the case. He's pleaded not guilty. He also faces several charges involving domestic violence against Phelps this year. 

Nicholas Ecker

Court records showed Ecker, who was barred from contacting Phelps after he was charged with domestic violence, was inside the home minutes before firefighters responded to the blaze.

Courtesy KCTV

The Associated Press contributed to this report. This story has been corrected to reflect the sentence of probation after a dispositional departure.