Teen Mom OG alum Ryan Edwards will be released from prison and sent to an inpatient rehab facility after serving three months of his one-year sentence. 

The former reality star, 35, appeared in court in Hamilton County, Tennessee, on Friday, July 14, where Judge Starnes announced that Ryan would be given a furlough to complete an inpatient rehab program, according to court records viewed by In Touch

“It’s time for you to go to the program. It’s your last chance to do this,” the judge stated, according to a reporter from The Sun, who was present for the hearing. “You need to do what you can. If you violate rehab, if you leave, you’ll be charged with escape and you will get consecutive sentences.”

Judge Starnes admitted to viewing Ryan’s lengthy medical history, which he called “disturbing,” before adding, “You don’t want to spend two to three years in custody if you can get treatment.”

A rep for the rehab facility which the Tennessee native will be attending announced that a bed will be available for Ryan on Tuesday, July 18. 

“We will be making some sort of treatment plan,” the rep added, per the outlet, confirming that Ryan will not be allowed to leave the facility unsupervised. “He can go there then go to OASIS, the halfway house. They live there. He would also get the injection.”

In addition to four weeks of inpatient rehab amid his release from custody, Ryan’s no-contact order with estranged wife Mackenzie Edwards (née Standifer) was lifted during Friday’s hearing, In Touch can confirm. 

A lawyer for the former MTV star reportedly claimed that Ryan “wants to speak with [his children] on the phone,” and the only way to do so is through their mother, Mackenzie. According to The Sun, the prosecution agreed that Mack “understands it’s important for the kids to communicate [with Ryan], as they ask about him.”

Friday’s hearing was the latest event in a string of Ryan’s legal troubles which began when he was arrested on February 10 and charged with harassment and possession of a controlled substance after he violated an order of protection by Mackenzie. He was arrested again on March 1 for stalking and violating an order of protection

Judge Starnes dropped most of the charges stemming from his arrests during a March 14 court hearing. He also ordered the father of three to complete six months in rehab, after which his charge of possession of a controlled substance would be dismissed. When Ryan checked himself out of an Austin, Texas, rehab center after just two weeks of treatment, he was arrested again on April 7 after being found unresponsive in his truck

According to an arrest affidavit obtained by In Touch, Ryan was “removed from the vehicle and placed in [an ambulance], where he received Narcan and eventually regained consciousness.”

“A quick search of Ryan Edwards by EMS turned up a small bag of what appeared to be a crystal-type substance and a second small bag of what appeared to be a blue powder,” the legal documents read. “Also in the pocket was a paper receipt that had been rolled up.”

Ryan was sentenced to 11 months and 29 days in prison on April 20. He is due back in court on August 14. 

Have a tip? Send it to us! Email In Touch at contact@intouchweekly.com.