SAN MARINO, Calif. -- The mayor of a Southern California city near Los Angeles has stepped down after he was captured on surveillance video tossing a bag of dog waste onto his neighbor's walkway earlier this month, CBS Los Angeles reports.

Dennis Kneier announced his immediate resignation Tuesday in a letter to the city and the City Council.

"As is well known, early in the evening of Saturday, June 7, I had a lapse of judgment and discarded dog waste on a neighbor's walkway," Kneier wrote. "It was insensitive, disrespectful and wrong. I have apologized to my neighbor for my action, and I will pay a fine for littering. I can understand why this matter has some questioning my ability to lead the council. I want to assure you that something like this will not happen again."

Get Breaking News Delivered to Your Inbox

Philip Lao, Kneier's neighbor, has said that the two men have been embroiled in a feud since 2008 because he disagrees with some of the mayor's proposals.

Vice Mayor Eugene Sun will assume mayoral responsibilities through June 27, when the council will select a new mayor and vice mayor.

Kneier will remain a councilman until his term ends in November 2015.