The NYPD’s case against a hemp wholesaler went up in smoke Tuesday — but what happens to the confiscated pot of pot now is anyone’s guess.

The Brooklyn DA’s Office told a judge that it was dropping all six felony drug-trafficking charges against middleman peddler Green Angel CBD — because what cops thought was 106 pounds of illicit pot was actually legal hemp.

At the time of last month’s bust, the Police Department crowed about the arrest — even tweeting a photo of the mounds of confiscated greenery along with two cops from Brooklyn’s 75th Precinct, saying, “Great job by Day Tour Sector E.

“They were able to confiscate 106 Lbs. of marijuana, and arrest the individual associated with the intended delivery,” the department glowed.

The tweet has since been deleted.

Prosecutor Kerri Row told Judge Raymond Rodriguez on Tuesday, “The People have been presented with evidence that the substance seized in this case contains less than .06 percent THC, which makes the substance legal hemp under federal and now state law.”

THC is tetrahydrocannabinol, one of the chemicals in marijuana that produces its high.

“The new law places the development and enforcement of regulations pertaining to hemp squarely in the jurisdiction of the [state] Department of Agriculture, and in light of this, we consider this case to be more appropriately dealt with as a regulatory than a criminal matter,” the ADA said.

“Accordingly, pursuant to our prosecutorial discretion, we move to dismiss the charges in this case.”

Still, while the prosecutor said her office has no use for the hemp — estimated at being worth up to $60,000 on the retail market by Green Angel — she said the NYPD would hold onto it, at least for now.

“Because the substance appears to have been imported outside of New York’s regulatory guidelines, the release of the property would be a determination to be made by the NYPD in consultation with the Department of Agriculture,” Row said.

Prosecutors and cops say Green Angel did not have a required permit for the product.

The assertion infuriated Green Angel’s owner, Oren Levy, and his lawyer, who got into a shouting match with a DA office spokesman outside court.

The DA rep, Oren Yaniv, said that by law, “All processors need to have a license, and your client doesn’t have a license!”

Green Angel lawyer Michael Arbeit retorted, “He’s a wholesaler! Processor means a farmer!”

Yaniv said, “We’re not guessing! We know! It’s over, anyway!”

The NYPD, in a statement to The Post, still insisted that the plants were “illegal marijuana,” saying, “In New York State, hemp sale and possession/distribution is only permissible when the buyer and seller have the proper permissions from the New York State Department of Agriculture and Markets. In this case, neither the seller nor the buyer had those permissions.”

Another Green Angel lawyer, Sanford Rubenstein, told The Post that he would be filing a notice of claim against the NYPD and city Wednesday alerting them to a planned $10 million lawsuit. Rubenstein said other claims could follow.

Additional reporting by Bernadette Hogan