Actress Lindsay Lohan posted a $300,000 bail and was released from jail, the Los Angeles, California, Sheriff's Department said Saturday.
On Friday, Judge Eldin Fox sent Lohan to jail for violating her probation after she tested positive for controlled-substance use.
However, Judge Patricia Schnegg granted Lohan's bail after her lawyer, Shawn Chapman Holley, filed a writ of habeas corpus just before court closed Friday afternoon, Parachini said.
Lohan's supervised probation for a 2007 drunken driving conviction requires frequent drug tests. The judge warned her last month that any failure could send her back to jail.
"Regrettably, I did in fact fail my most recent drug test and if I am asked, I am prepared to appear before judge Fox next week as a result," Lohan tweeted on September 17.
She spent 23 days in a court-ordered drug rehab program last month, which followed a 13-day jail stint imposed when a Los Angeles judge ruled that Lohan violated her probation.
Fox, who took over Lohan's case when she was released, imposed a new set of rules for her to follow until November. It included weekly counseling sessions for alcohol and drug rehabilitation, random drug tests and behavioral therapy.
"Substance abuse is a disease, which unfortunately doesn't go away overnight," Lohan tweeted. "I am working hard to overcome it and am taking positive steps."