Hillary Clinton's presidential campaign released a television ad featuring Morgan Freeman and making the case that the Democratic front-runner is fighting for racial equality in the United States. (Hillary Clinton)

Both Hillary Clinton and Sen. Bernie Sanders are airing ads in Maryland that invoke the deaths of African Americans in police custody as the candidates seek to show their commitment to criminal justice reform.

It’s a sign of the importance both candidates are placing on the April 26 presidential primary in Maryland, where more than a third of the Democratic electorate is African American.

Recent polling suggests Clinton has a strong advantage in Maryland over Sanders (Vt.). An NBC-Marist poll released Tuesday gave her a 22-point lead over Sanders, 58 percent to 36 percent. A Washington Post-University of Maryland poll from last week gave Clinton a 15-point lead, 55 percent to 40 percent.

But her lead has shrunk in recent months as Sanders has gained ground.

In Clinton’s ad, narrated by actor Morgan Freeman, the former secretary of state names African Americans who have been shot and killed or died in police custody.

“She fought in the Senate to end racial profiling and discriminatory sentencing and stands with the president against those who would undo his achievements,” Freeman says. “Just like she has always stood with us.”

Sanders’s ad features the daughter of Eric Garner, who died after being put in a chokehold when stopped by police officers in New York two years ago.

“People are dying. We need a president that’s going to talk about it,” Erica Garner says. “I believe Bernie Sanders is a protester. He’s not scared to go up against the criminal justice system.”

Clinton has an overall delegate lead in the race that will be almost impossible for Sanders to overcome. But both candidates would like to claim momentum by doing well in Maryland, where 95 delegates are at stake.

Former president Bill Clinton will appear Wednesday afternoon at Leisure World, an 8,500-person retirement community in Silver Spring known for being home to many engaged Democratic voters. Hillary Clinton held an organizing rally in Baltimore on Sunday with Sens. Benjamin L. Cardin and Barbara A. Mikulski and Rep. Elijah E. Cummings.

Sanders toured West Baltimore in December. He recently announced the support of several local civil rights activists, including former NFL linebacker Aaron Maybin.