A federal judge in Seattle opened the door Thursday for thousands of immigrants to apply for asylum, finding that the Department of Homeland Security has routinely failed to notify them of a deadline for filing their applications. U.S. District Judge Ricardo S. Martinez issued the ruling in a class-action lawsuit brought by immigrant rights groups on behalf of those who fear persecution if returned to their home country. In many cases, those asylum seekers are released from custody after officials have interviewed them and determined their fears to be credible. They’re told that they’ll need to appear in immigration court, but they typically aren’t personally told that they only have a year to apply for asylum, the lawsuit argued.

Due to a backlog in immigration cases, the asylum seekers are often not given a hearing within a year, and thus, by the time they show up in court and learn about the deadline, it’s already passed, Martinez found.

“This means many asylum seekers who were previously going to have a door slammed in their face are now able to say, ‘No, a federal court has said that I am timely filing my application and you need to accept it,'” said Matt Adams, legal director of the Northwest Immigrant Rights Project and an attorney for the plaintiffs. The judge ordered the department to begin providing notice about the one-year deadline within 90 days any time an immigrant seeking asylum is released from custody pending deportation proceedings. He also said the department must give those who missed the deadline another year to file their applications. Further, Martinez told the department it must fix another catch-22 in its system: that while asylum-seekers must file their asylum applications within a year, the government refuses to accept the applications unless the applicant has been given a formal notice to appear in immigration court.