Pasadena’s public health director has been placed on leave over anti-gay remarks.

Pasadena City College had intended for Milk screenwriter Dustin Lance Black to be commencement speaker, but he was uninvited after pictures of him engaging in sex acts leaked online.

He was due to be replaced by the city’s public health director Eric Walsh, but Walsh was also uninvited, after it emerged he had made a series of anti-gay speeches as a pastor.

Pasadena City Manager Michael J. Beck said in a statement that Walsh has been place on paid leave, while his comments are investigated.

He said: “Dr. Eric Walsh has been placed on temporary paid administrative leave to provide the city of Pasadena the opportunity to complete an inquiry into statements made by him in his private capacity and to assess the impact those statements might have on his ability to effectively lead the city’s Public Health Department.

“The Public Health Department remains a strong and vital part of the city of Pasadena organization and remains dedicated to protecting the health and wellness of our entire community.”

Walsh attracted criticism after footage surfaced of a 2006 speech in which he condemned US schools for ‘accepting’ homosexuality.

He has also taken aim at TV shows such as Will and Grace for encouraging acceptance of gay people.

Dustin Lance Black is currently dating British diver Tom Daley.