A former student at SUNY Potsdam plead guilty on Tuesday morning, avoiding hate crime charges after he sent racist, homophobic letters to a professor at the college.

Amjad Mark Hussain plead guilty to aggravated harassment and criminal solicitation. He faces three years’ probation, reports WWNYTV. He must also complete 100 hours of community service and attend counseling.

There is also an order of protection against the victim, Dr. John Youngblood.

He sent letters on two occasions and threatened Youngblood’s life, as well as his family, according to the Watertown Daily Times. He also had another student send a threatening letter after his arrest.

“Based upon my conversations with Mr. Hussain, he was relieved. It’s always beneficial to know what’s going to happen to you instead of course leaving that fate up to the hands of a jury foreperson,” said Ed Narrow, Hussain’s defense lawyer.

Sentencing is set for March 14.

President of the college, Dr. Kristin Esterberg, released a statement about the case and the plea deal.

“Mr. Hussain was charged with delivering two messages to a SUNY Potsdam faculty member in April 2015, which included death threats and racist and homophobic language. He was also charged with soliciting another individual to deliver a third threatening hate note in November 2015,” he wrote.

“Our hearts go out to the victim and to their family, following this step toward resolution in this case. Today’s events are an important reminder that our community will not tolerate racism, homophobia, bigotry or threats of violence.

“An order of protection remains in place for the victim, and Mr. Hussain continues to be prohibited from entering the SUNY Potsdam campus.

“We would like to thank Assistant Attorney General Mary A. Gorman of the Public Integrity Bureau, who prosecuted this case on behalf of the Office of New York State Attorney General Eric Schneiderman.

“In addition, we would like to recognize SUNY Potsdam University Police and our law enforcement partners who assisted with this case, including the Federal Bureau of Investigation, the Department of Homeland Security Computer Crimes Unit, the New York State Police, the NYS Police Bureau of Criminal Investigation, the NYS Forensics Investigation Unit, the St. Lawrence County Sheriff’s Department, Potsdam Village Police, Canton Village Police, Elmira City Police and our partner SUNY University Police agencies.”

Watch a report in the video below.