(CNN) Marijuana possession cases, regardless of quantity or a person's criminal record, will no longer be prosecuted in Baltimore, State's Attorney Marilyn Mosby announced Tuesday.

In a statement released by her office , Mosby said her staff will stop prosecuting the cases because they have no public safety value, they disproportionately affect communities of color and erode public trust. She also said they are costly and a counterproductive use of limited resources.

"We need to get serious about prioritizing what actually makes us safe," said Mosby, "and no one who is serious about public safety can honestly say that spending resources to jail people for marijuana use is a smart way to use our limited time and money."

In the announcement, she said her office will continue to prosecute distribution of marijuana cases as long as there is sufficient evidence of intent to distribute. Anyone charged for the first time with felony possession with intent to distribute or with felony distribution will be referred to a diversion program.

Ten states and the District of Columbia have legalized small amounts of marijuana for adult recreational use, but in Maryland only medical use of marijuana is legal. In 2014, legislation was approved in Maryland to decriminalize possession of small amounts of marijuana.