A man was arrested Friday night in connection with anti-Semitic messages found inside a Brooklyn synagogue before a get-out-the-vote event with Ilana Glazer.

The NYPD said 26-year-old James Polite of Brooklyn has been charged with Criminal Mischief for a Hate Crime and Making Graffiti. Authorities said they expect Polite will receive a psychiatric evaluation.

Police said a member of Union Temple in Prospect Heights found the messages around 8:30 p.m. Thursday before Glazer, an actress in the show "Broad City," was scheduled to speak.

Police said "Hitler" was found written on the first-floor staircase, and the message "Jews better be ready" was found on the third-floor staircase. Officials said other graffiti that wasn't anti-Semitic was also found.

The graffiti was painted over by Friday evening:

 

 

 

Police are investigating whether the man in custody is also responsible for the reported arsons of temples in Williamsburg on Friday morning.

Speaking with the media outlet Democracy Now! in the morning, Glazer said concern for the people gathered led to organizers cancelling the get-the-vote event.

The NYPD's chief of detectives said the city has seen a spike in reported anti-Semitic crimes over the past few weeks.

Mayor Bill de Blasio joined the Union Temple congregation for Shabbat services Friday as a show of solidarity. It is the synagogue's first Shabbat service since 11 people were gunned down at the Tree of Life synagogue in Pittsburgh last Saturday.