A Black Michigan teenager has been released from a juvenile detention facility after she was detained for not completing her online schoolwork during the coronavirus pandemic, according to The Detroit News. 

Prosecutors in Michigan advocated for the teen, known by her pseudonym Grace, to be released from the facility after a judge called for her to be taken into custody for not turning in her homework and declined to release her following uproar over her case.

On Friday, the Michigan Court of Appeals ordered Grace to be released immediately, overruling the family court judge, reports The Detroit News. 

The 15-year-old was thrown into juvenile detention in May. When the story was uncovered by ProPublica earlier this month, people across the country called for Grace to be released and said her incarceration was a clear example of the harsh treatment often directed toward Black girls.

"We’re so happy that Grace is going to go home with her mom and sleep in her own bed tonight. She'll be where she belongs, really," the teen's attorney Jonathan Biernat said.

The Oakland County Prosecutor’s Office said it was in support of Grace's release in a message to the appellate court, reports the Detroit Free Press.

“There is absolutely no doubt that public pressure turned the tide for Grace and her mother. We must continue dismantling the systems that allow young, Black girls like Grace to be incarcerated at a disproportionate rate," U.S. Rep. Andy Levin said. 

The Free Press reported that Grace's lawyer filed an emergency petition for her case to be heard by the appellate court. Biernat pushed the court to release its opinion by August 3. 

“We are very thankful to the Oakland County prosecutor for their concurrence in this matter. It is clear they see the injustice in Grace’s continued detention,” Biernat said. 

As Blavity previously reported, Judge Mary Ellen Brennan refused to let the teen go back to her family.

Grace told the court, "I miss my mom. I can control myself. I can be obedient."

But Brennan denied the request, telling the court that she was making progress.

"Give yourself a chance to follow through and finish something. The right thing is for you and your mom to be separated for right now," Brennan said.

“I think you are exactly where you are supposed to be. You are blooming there, but there is more work to be done,” Brennan added. 

The case has sparked protests, petitions and scrutiny from national legislators. A group of lawmakers — Massachusetts Rep. Ayanna Pressley and Michigan Reps. Rashida Tlaib, Levin, Debbie Dingell, Brenda Lawrence and Haley Stevens — sent a letter to the U.S. Department of Education and the U.S. Department of Justice demanding Grace's release.

Among a host of reasons, the lawmakers said the COVID-19 pandemic made it unconscionable to keep the teen detained at the Children’s Village detention center and that Grace's case is representative of what many Black children face when dealing with the criminal justice system.

ProPublica combed through data from Michigan and found that between January 2016 and June 2020 nearly half of the almost 4,800 Oakland County court juvenile cases involved Black children despite them representing just 15% of the population.  

Brennan has defended her decision to keep Grace detained by citing the child's record from last year when she was a sophomore at Groves High School. Grace was accused of assault and theft after allegedly biting her mother and stealing a cellphone. 

After placing Grace on probation on April 21, Brennan found Grace in violation on May 14 because she was not submitting her homework. Brennan later changed her reasoning for detaining Grace, saying it was not about the homework but that the child was a “threat to [the] community” for her actions toward her mother. Grace's mother has denied this in court.

Grace has been diagnosed with ADHD and is enrolled in special education services. She said that when the state's schools moved to online learning, she struggled to keep up, as many students across the country have reported

“While Grace has faced many personal challenges in her young life, it was her lack of completion in online coursework that the judge cited as the definitive reason for sentencing Grace to juvenile detention. This is simply unacceptable,” the lawmakers wrote in their letter.

“Particularly as schools ready for the upcoming academic year, we must be clear that our children should be provided with additional supports and services, they should not be criminalized for their lack of engagement in online instruction,” the lawmakers added.