Justin Bieber has reached a plea deal in his Miami DUI arrest in which he will plead guilty to reckless driving, pay a fine and attend anger management classes

Bieber was charged with driving under the influence, drag racing, driving with an expired license and resisting arrest without violence in January, but authorities have dismissed a couple of the charges after it was determined that the singer wasn't intoxicated or drag racing at the time of his arrest. He was, however, under the influence of marijuana.

TMZ reports, the settlement in the case took so long because the prosecution was trying to get Bieber to produce, finance and star in an anti-drug PSA. After the singer's team resisted the prosecution's demand claiming it was unfair, a judge eventually threw it out.

Bieber's management also fought the prosecution's request that he attend a drug and alcohol abuse course claiming Bieber did not suffer from a substance abuse problem and that attending the class would seem like an admission that he did.

After the singer has completed the terms of his deal, the reckless driving charge will be wiped from his record. Additionally, Bieber will not be placed on probation.