Michigan medical marijuana patients who have been fired from a job for failing a drug test can still receive unemployment benefits, according to a verdict handed down last week by a state court of appeals.

A panel of judges found that the state’s medical marijuana law holds more weight than its unemployment law, and therefore anyone dismissed from work duties as a result of using medical marijuana should be allowed to receive benefits.

This ruling is in response to three recent cases in which employees were terminated solely for violating workplace drug policies with the use of medical marijuana. In all three cases, a judge ruled in favor of the workers. Friday’s verdict upholds all three decisions.

Although it is still legal for an employer to fire an employee for testing positive for medical marijuana, those workers will be permitted to collect unemployment benefits.