In a victory for state medical marijuana programs and patients, a federal court in California ruled Monday that federal authorities may not shut down medical pot dispensaries operating within state laws.

Under Rohrabacher-Farr amendment, which accompanied last year’s spending bill, the Justice Department can not use federal dollars to interfere with state medical marijuana laws and practices, preventing the DEA from pursuing dispensaries and patients, the court ruled, according to the Washington Post.

The decision follows a leaked Justice Department memo that interpreted the amendment as offering protections limited to the actual states, not the individuals and businesses which deal with the day-to-day implementation of marijuana laws. As a result of the DEA’s continued enforcement, several dispensaries have been closed in California, including one owned by the Marin Alliance for Medical Marijuana, the first licensed medical pot dispensary in the state.

Judge Charles Breyer of the U.S. district court in northern California disagreed with the DEA memo, writing in his decision that the department’s interpretation of the law “defies language and logic” and is “at odds with fundamental notions of the rule of law.” Instead, the court sided with the dispensaries, saying the department could not interfere with medical marijuana providers operating legally under state regulations.

The ruling is a huge win for California’s dispensaries, who have battled with the DEA for years over the legality of their business practices, the Post notes. The decision could also discourage the Department of Justice from cracking down on medical marijuana in the other 23 states with where the substance is legal.

[Washington Post]

Get The Brief. Sign up to receive the top stories you need to know right now. Please enter a valid email address. Sign Up Now Check the box if you do not wish to receive promotional offers via email from TIME. You can unsubscribe at any time. By signing up you are agreeing to our Terms of Use and Privacy Policy . This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply. Thank you! For your security, we've sent a confirmation email to the address you entered. Click the link to confirm your subscription and begin receiving our newsletters. If you don't get the confirmation within 10 minutes, please check your spam folder.

Contact us at letters@time.com.