The police officer at the center of a viral incident at a McDonald's in Junction City, Kansas, said he wrote "f---ing pig" on his own coffee cup. Yves Herman/Reuters

A police officer in Kansas resigned on Monday after admitting that he lied about a McDonald's employee writing "pig" on the cup of coffee he ordered at the chain.

A Facebook post by Brian Hornaday, the chief of the Herington Police Department, showing the cup with "f---ing pig" written on it went viral over the weekend.

"While we are glad that the evidence confirmed our evaluation that the McDonald's and our employees, crew members were absolutely not involved, we stand with our community in being disappointed about these actions," said Lenor Brazzi, the director of operations for the McDonald's franchise.

"In that investigation we have found that McDonald's and its employees did not have anything whatsoever to do with this incident," Hornaday said. "This was completely and solely fabricated by a Herington police officer who is no longer employed with our agency."

Sign up for Business Insider's retail newsletter, The Drive-Thru .

. Visit Business Insider's homepage for more stories.

The police officer at the center of a viral incident at a McDonald's in Junction City, Kansas, admitted to writing "f---ing pig" on his own coffee cup.

A Facebook post by Brian Hornaday, the chief of the Herington Police Department, claiming that a McDonald's employee had written "f------ pig" on an officer's receipt went viral over the weekend. On Monday, the unnamed officer resigned after admitting that he lied about the incident, The New York Times reported.

Hornaday's post prompted an internal investigation by the restaurant and the department. As the post went viral, the McDonald's franchise provided video footage showing that employees didn't write anything on the officer's cup.

"We appreciate the Herington Police Department's efforts to thoroughly investigate this troubling incident," Lenor Brazzi, the director of operations for the franchise, said in a joint press conference with the department on Monday.

"While we are glad that the evidence confirmed our evaluation that the McDonald's and our employees, crew members were absolutely not involved, we stand with our community in being disappointed about these actions," Brazzi continued. "We took seriously our role to be transparent and fully cooperative with Chief Hornaday and his department throughout his investigation."

Hornaday praised the Junction City McDonald's and its employees for being honest and transparent throughout the investigation.

"In that investigation we have found that McDonald's and its employees did not have anything whatsoever to do with this incident," Hornaday said. "This was completely and solely fabricated by a Herington police officer who is no longer employed with our agency."

Hornaday said that the officer in question is a resident of Junction City and that the department would not release his name as the matter is a "personnel issue." Hornaday said the officer had meant the note to be "a joke."

"However, we can see how something so serious can get so out of control very, very quickly," the Herington police chief said. "The most important thing that could have been done and should have been done in this scenario was to come forward immediately prior to damage being done, prior to this becoming a nationwide incident. However, unfortunately, that was not done."

Brazzi said the franchise looked forward to continuing its strong relationship with the Herington Police Department.

"Our McDonald's family maintains great respect for all members of law enforcement and our military, and it is a great pride that our restaurant is always open to them," Brazzi said.

The hoax was the most recent in a string of viral incidents in which police officers have posted photos that appear to show employees referring to them as "pigs." In November, Starbucks fired an employee after an officer said the employee wrote "pig" on his coffee cup instead of his name.

NOW WATCH: Popular Videos from Insider Inc.