California does a good job of letting medical marijuana patients get their treatment of choice, but some elements of the state’s marijuana laws still fail to protect people with legitimate ailments, according to a report released Thursday by a patient advocacy group.

Americans for Safe Access said the Golden State was one of three states to receive a B+ grade – the highest issued by the group – and commended California for having an abundant supply of cannabis, reasonable taxes, the right to home cultivation and few limits on medical conditions that qualify for treatment.

“The really good news in California is that if you’re medical cannabis patient, you can almost surely get access to your medicine,” said Don Duncan, California director of Washington, D.C.-based organization.

But the report also states California has a ways to go when it comes to protecting civil rights for medical marijuana patients and improving consumer safety.

“We still have some unfinished work to do,” Duncan noted.

No state has ever earned an A in the three years that Americans for Safe Access has issued its annual report, according to Steph Sherer, the group’s founder and executive director. But overall, she said access in the United States is the best it’s ever been, with five more states legalizing medical marijuana and many more taking steps to boost access in 2016.

“What was really exciting was that 23 states took our recommendations from last year and improved their laws,” Sherer said.

That included California, which was the first state to legalize medical marijuana in 1996.

Though the state didn’t pass any new medical marijuana legislation in 2016, Americans for Safe Access and others lobbied to get new protections for patients included in Proposition 64, the recreational marijuana measure approved by voters in November. That included a stipulation that Child Protective Services can no longer restrict parental rights based solely on the fact that someone is a medical marijuana patient.

Those protections helped California earn a 10-point improvement in the organization’s annual ranking, giving it that B+ score along with Michigan and Illinois.

Americans for Safe Access always gives states the benefit of the doubt that when they pass new legislation that they will actually implement those policies, Sherer said. So California’s high score is based on the assumption that it will carry out protections both in Prop. 64 and in a trio of bills passed in 2015, known as the Medical Cannabis Regulation and Safety Act.

The big test will come this year, with a Jan. 1, 2018 deadline for California to roll out its new marijuana licensing and regulatory scheme.

“What’s key is just going to be getting the medical cannabis program implemented and getting the state licenses out,” Sherer said.

If it doesn’t, she said the state’s score could potentially drop significantly next year.

California’s 2016 grade was unchanged from 2015. But the vast majority of others states improved their scores.

Florida, for example, moved from an F to a B- after voters legalized medical marijuana in November. Montana and Michigan also made big strides in 2016. While both states already had medical cannabis laws on the books, until last year, they had no centralized distribution system in place so patients could actually get access to cannabis.

More than a dozen states still received Fs, including Alabama, Mississippi and Texas. But overall, there was a 58 percent increase in the number of states scoring a B and 12 percent increase in states scoring a C.

For the first time, the report gave a few states negative points.

Maryland and Massachusetts both lost points because their medical marijuana programs are taking so long to roll out, Sherer said.

“These programs are useless if they don’t put them into action,” she said.

The third state to lose points was Washington, which merged its medical and recreational marijuana programs in 2016 – an idea that’s been floated in other legal weed states, including California.

“Where it may seem like a good idea on paper, it has a detrimental impact on patients,” Sherer said, noting that patients in Washington now face reduced access, product restrictions and privacy concerns. She hopes that will serve as a “canary in the coal mine” moment for other states that might be considering whether to merge their medical and recreational programs.

Americans for Safe Access ranks states based on how well they meet the needs of patients in five categories, from patients rights to ease in navigating the program to consumer safety. States can also receive up to 25 bonus points for passing legislation or regulations that improve any of the above areas.

Read the full report here.

California scored in the 90s out of 100 possible points for access, ease of navigating the program and functionality.

The state scored 77 for patient rights. The report notes California remains “the best place in the country” for patients to get legal protection and quick access to medicine. But it said “the state still lags on providing civil discrimination protections for its patients.”

Workers in California can still be fired for having marijuana in their system, for example. Sherer said her group has tried several times to pass legislation that would change that, but has found the biggest opposition coming from the powerful Chamber of Commerce.

California also scored just 59 out of 100 for consumer safety.

While the new medical marijuana laws and Prop. 64 both add a number of protections – including mandatory testing and a tracking program – the report says the state still needs to adopt stronger product safety regulations. That includes boosting requirements for staff training, adding a system for recalling unsafe products and adopting standards for sanitary workplaces.

Here’s a look at the raw score (out of 100) and letter grade each state’s medical marijuana program earned from Americans for Safe Access in 2016, plus how those figures compare to their 2015 ranking.