A high school teacher in upstate New York issued a public apology this week after his comments at a senior awards ceremony ignited controversy in the Whitesboro community.

Whitesboro High School English teacher Andrew Puckey attempted to end the livestreamed senior awards on a positive note, but now faces allegations of racism over the remarks.

MORE NEWS: VIDEO: Ron Paul appears to suffer ‘stroke’ during livestream

“Remember: In Whitesboro, all lives matter,” Puckey said at the end of the program Friday. “Be kind to each other and have a wonderful night. And thank you for tuning in this evening. We appreciate you being with us.”

The closing statement, including the controversial “all lives matter” comment, was cut from the video posted to the district’s website, but Twitter user “Mealz” posted a clip along with Puckey’s email address online, WIBX reports.

The situation snowballed from there, igniting a war between Black Lives Matter activists and the teacher’s supporters online. Black Lives Matter supporters believe the “all lives matter” phrase dismisses the movement for social justice, and the blowback in Whitesboro prompted a statement from the school district and an apology from Puckey, the Utica Observer-Dispatch reports.

“Rather than convey a positive message as I attempt to do at the end of each awards ceremony, it instead caused hurt to many in our community,” Puckey wrote in a letter posted to the district website.

The teacher contends he didn’t realize the “all lives matter” phrase carried “deeply political and racial undertones.”

“I understand that many of you are deeply hurt,” Puckey wrote. “Words can have that power. However, words can also heal. It is my hope that we can use this experience to open communication and education in the school district as a whole. We do not have to be swallowed by the hatred and the darkness if we can shine as a light.”

MORE NEWS: UI prof scrambles to rewrite slavery assignment after student complains on Twitter

Whitesboro Superintendent Brian Bellair posted a statement to the district’s website about the “pain and grief caused by the acts of social and racial injustice throughout the United States and the world” that announced a new diversity and inclusion coordinator position, but he did not reference Puckey or the incident directly.

“The Whitesboro Central School District is fully committed to social justice and equity,” Bellair wrote to the Observer-Dispatch when asked for comment about Puckey’s remarks. “We are at a turning point in history and must seize the opportunity to move society forward in a positive way. Acknowledging the harsh realities of racism is the first step toward its eradication and a better world.”