David Leung, the former Assistant District Attorney busted for selling cops pot last September, has a perfectly good excuse for his alleged actions: He was depressed because he'd dumped his cheating wife.

See, Leung—who worked for the Manhattan District Attorney from 1993 through 2003 before going into private practice in Indiana—was just addicted to marijuana. According to court papers brought to court yesterday Leung told detectives that, "My wife cheated on me and I left her. I ... started smoking marijuana, smoking marijuana heavily. I got addicted to it."

According to police, Leung, 44, was busted by an informant on September 27, 2012, after he slipped the undercover agent two bags of weed for $200 on Ninth Street (they'd already agreed to the deal over the phone). After the exchange police say they found seven more bags of pot, totaling more than eight ounces, in the trunk of the car Leung was driving.

Whatever the police say, though, Leung yesterday pleaded not guilty to felony marijuana possession and a misdemeanor drug sale charge.