Selena Gomez has had a difficult week in the media, but at least she can rest easy this weekend.
Juan Daniel Garcia of Arizona pled no contest on Wednesday to a single count of trespassing on her property, the L.A. City Attorney's office confirms to "The Insider With Yahoo." The charge stems from an incident on Jan. 25 when Garcia was caught lurking on Gomez's property in the L.A. suburb of Tarzana.
Commissioner Dennis Mulcahey sentenced Garcia to 120 days in jail as a condition of 36 months of summary probation. He has been ordered not to contact Gomez and to stay at least 150 yards away from her and her residence. He is also ordered to submit to search and seizure at any time and forbidden from possessing any deadly or dangerous weapons.
[Related: Selena Gomez Admits Secret Rehab Stint]
It's not the first time Gomez, 21, has dealt with a seemingly obsessive fan. She has an existing three-year restraining order from January 2012 against a man from Illinois who allegedly stalked her and threatened to kill the singer-actress.
Earlier this week, her rep confirmed to "The Insider" that the starlet had voluntarily checked into Arizona rehab facility Dawn at the Meadows on Jan. 5. However, she checked out just two weeks later to attend the Sundance Film Festival in Utah.
"Selena voluntarily spent time at Meadows but not for substance abuse," he rep said, shooting down tabloid rumors that perhaps she was there dealing with an alcohol problem.
In December, Gomez announced that she was pulling the plug on the Australian leg of her "Stars Dance" tour. Following that announcement, she posted a pic to Instagram declaring that she was "the happiest I've been in a while."
It was a bad week for her ex, Justin Bieber, as well. After NBC News unveiled some pretty outrageous charges about his pot plane and subsequent treatment of some airline attendants, video surfaced of his arrest in Miami, and the L.A. District Attorney confirmed that they were seeking felony charges for his great egg-throwing caper.