Canadian Prime Minister Justin Trudeau delivered an official apology for his country’s past persecution of LGBTQ public servants on Tuesday.

The address delivered in the House of Commons comes just over a week after Trudeau announced he would apologize for Canada’s dehumanizing treatment of LGBTQ service members and other government employees throughout the second half of the 20th century.

“Imagine, if you will, being told that the very country you had willingly laid down your life to defend doesn’t want you, doesn’t accept you, sees you as defective, sees you as a threat to our national security,” Trudeau said Tuesday, speaking in both French and English.

“Not because you can’t do the job or because you lack patriotism or courage, no, but because of who you are as a person and because of who your sexual partners are.”

Roberto Machado Noa/LightRocket via Getty Images Canadian Prime Minister Justin Trudeau marches in Toronto's Pride Parade in June 2016.

From the 1950s until 1992, many public servants that Canada’s government suspected of being gay were interrogated, forced to sit through humiliating tests that sought to expose their sexual orientation, and expelled from their Canadian government positions.

That treatment happened on “a timeline more recent than any of us would like to admit,” Trudeau said Tuesday, calling the oppression “an often overlooked part of Canada’s history.”

One of the most egregious tools used was the “fruit machine,” a device he mentioned by name Tuesday that claimed to reveal a person’s sexual orientation based on their response to various sexual stimuli.

“It is my hope in talking about these injustices, in vowing to never repeat them, acting to right these wrongs, we can begin to heal,” Trudeau said.

Throughout his two years in office, Trudeau has also issued apologies for Canada’s past treatment of indigenous peoples and for the 1914 “Komagata Maru incident,” in which Canada rejected hundreds of Sikh, Muslim and Hindu passengers attempting to seek refuge in the country, forcing them to return to a violent situation back in India.