WASECA, Minn. (AP) — A 19-year-old accused of plotting an attack at a southern Minnesota high school will be placed in a state-operated facility after he's released from jail.

John LaDue was set to return to his Waseca home Thursday to live temporarily with his parents until officials found a bed for him at a state-run evaluation facility. But the state Department of Human Services was able to find a bed Wednesday, hours before LaDue was set to walk out of jail.

LaDue was 17 when he was arrested in April 2014 after police found him in a storage unit with bomb-making materials.

He was sentenced in October to 10 years of probation and an unspecified amount of time in a treatment facility as part of a plea deal.