@justinbieber / Instagram 1 / 10
@justinbieber / Instagram 1 / 10

VAN NUYS, Calif. (AP) -- Justin Bieber has pleaded no contest to a misdemeanor vandalism charge for throwing eggs at a home in his Calabasas neighborhood, and he's been sentenced to two years' probation.

RELATED: Selena Gomez gets moody on Instagram

Bieber was also ordered to pay $80,900 in damages, complete five days of community labor and a 12-week anger-management program, and stay away from the victim and his family for two years.

The Grammy-nominated singer was not present for the Wednesday arraignment at Superior Court in Van Nuys.

A spokeswoman for Bieber says he's glad to have the matter resolved and behind him.

RELATED: Stars show off sexy beachside selfies

Prosecutors spent months considering whether to file charges after the singer's mansion was searched following the January incident. A detective wrote that someone matching Bieber's description was seen on video high-fiving his friends at the time of the incident.