A police officer in western Pennsylvania lost her job hours after superiors discovered a picture she allegedly posted to Snapchat in full uniform, with a racial slur in the caption, the Pittsburgh Tribune Live reported.

"I'm the law today n----," Melissa Adamson, a former part-time police officer with the McKeesport, Pennsylvania, police department, allegedly wrote, leading to her termination.

A member of the public reportedly spotted the picture, which was sent out on the semi-private app Snapchat, and posted it on Facebook, sparking the outrage.

McKeesport Mayor Michael Cherepko denounced Adamson's post in the announcement that she would be fired.

"This post displays a degree of conduct and character that is far different from what I would expect from an officer in this city," Cherepko said in a Facebook post on Tuesday. "My office and the police chief’s office immediately concluded that this officer’s actions will not be tolerated in the City of McKeesport. She has been relieved of her duties, and her employment has been terminated."

Adamson formerly worked for the nearby Pitcairn Police Department and is wearing their uniform in the picture.

Further details about Adamson's employment and the reasons for her previous termination from another department were not immediately available.