Pharrell Williams reportedly sent President Trump Donald John TrumpBiden says voters should choose who nominates Supreme Court justice Trump, Biden will not shake hands at first debate due to COVID-19 Pelosi: Trump Supreme Court pick 'threatens' Affordable Care Act MORE a legal warning after his song, “Happy,” was played at a rally just hours after the Pittsburgh synagogue shooting.

According to the New York Daily News, a lawyer representing the musician filed a cease and desist letter against Trump on Monday.

"On the day of the mass murder of 11 human beings at the hands of a deranged 'nationalist,' you played his song 'Happy' to a crowd at a political event in Indiana," reads a letter obtained by the newspaper.

ADVERTISEMENT

"There was nothing 'happy' about the tragedy inflicted upon our country on Saturday and no permission was granted for your use of this song for this purpose,” the letter continued.

The musician also reportedly said that the president is not permitted to play any of his music without his permission.

Eleven people were killed and more wounded when a gunman opened fire at a synagogue in Pittsburgh on Saturday morning, just hours before Trump’s political event in Indiana.

Robert Bowers faces 29 charges, including 11 counts of use of a firearm to commit murder and 11 counts of obstruction of the exercise of religious beliefs resulting in death, for the attack.

A number of other musical artists have also called for their songs to no longer be played at Trump's public events, including Prince, Aerosmith's Steven Tyler, Twisted Sister and Elton John.