Sen. Elizabeth Warren’s speech at Reid Chapel AME Church on Sunday in Columbia, S.C., included an anecdote about a time she struggled to control a Sunday school class. (Meg Kinnard/AP)

At services Sunday morning, a pastor misidentified Sen. Elizabeth Warren’s husband. The day before, the man introducing Warren at the Black Church PAC presidential candidate forum in Atlanta inaccurately said she was from the “great state of New Hampshire.”

The mistakes were minor, but they show the Massachusetts Democrat is struggling to introduce herself to black voters, even after eight months of nonstop campaigning.

Other candidates, including Sen. Bernie Sanders (I-Vt.) and South Bend, Ind., Mayor Pete Buttigieg, also tried to expand their appeal among nonwhite voters this weekend, as they campaigned in South Carolina and Georgia.

Black voters are key to winning South Carolina, the fourth nominating contest in the Democratic calendar, along with the slew of Southern primaries where African Americans also represent large shares of the vote. Hillary Clinton won the 2016 Democratic presidential primary here because of her support among black voters.

Buttigieg, whose support among blacks has been too small to measure in some polls, spent his Sunday morning glad-handing at Bethel AME church in Georgetown, S.C. Later, during an interview on CNN’s “State of the Union,” he made an appeal to blacks, saying President Trump’s supporters are “looking the other way on racism.”

Sanders used his trip to release a wide-reaching criminal justice plan. “This state is a state which has an even more broken criminal justice system than the country, and the country is pretty bad,” Sanders said.

His plan would end for-profit prisons, abolish the death penalty, set national standards for the use of force by police officers and cut the prison population in half.

“We have the wealthiest country in the history of the world, and yet we have more people in jail today — 2 million people — than any other country on Earth,” Sanders said at a partitioned-off area at a luncheon hosted by Brookland Baptist Church in West Columbia.

Although black churchgoers ate nearby, Sanders delivered his remarks to a group of mostly white voters who came just to see him. Several Sanders supporters insisted they shouldn’t have to pay for the luncheon since they had come only to hear the candidate.

The overall effect — a crowd of largely white outsiders descending on a weekly lunch for a black church — alienated several churchgoers.

“I was eating when he spoke,” said Maxine Moses, an African American woman. Although she sat with her son just feet from Sanders, she didn’t go listen to him. “I might have gone and listened to him if he had attended the Sunday service,” she said.

Sanders was better received the day before in Atlanta, when he briefly diverted from his typical stump speech to talk about his opposition to racism.

“I’m Jewish. My family came from Poland. My father’s whole family was wiped out by Hitler and his white nationalism,” Sanders told a mostly young black audience in Atlanta.

“Our job is to fight racism at every level,” Sanders continued. “We will go to war against white nationalism and racism in every aspect of our lives.”

Sanders has made inroads among blacks, with a recent Fox News poll showing he’s the first pick of 18 percent of black voters. Warren was the first choice among 8 percent of black voters.

But in South Carolina, Warren and her team appeared to be navigating the racial landscape more astutely than Sanders. Among the speakers warming up a crowd for her Saturday evening in Aiken, S.C., was Lessie Price, a local black leader and the first vice chair of the state’s Democratic Party.

Warren’s message, Price said, speaks to African Americans. “Often­times, it’s getting that message out over and over and over, and someone starts hearing it,” said Price, who is staying neutral in the primary.

Speaking to a black church is particularly sensitive, she said. “The church in the past has been a rallying point to really see what a candidate is truly about,” Price said. “You have to change your message in that setting.”

And Warren adjusted her rhetoric when she stepped up to the pulpit at a sparsely attended service at Reid Chapel AME Church on the other side of Columbia on Sunday morning. Rather than her usual firebrand stemwinder, she talked about her hardscrabble biography, including an anecdote about how she once struggled to control an unruly fifth-grade Sunday school class.

“They cut each others’ hair during the art project,” Warren said, adding touch of Southern cadence to her voice. “Oh! They spilled things on each others’ clothes. It was wild. The boys climbed out the window.”

Warren said she used the story of Noah and the ark to capture the imagination of the class. “I started asking the kids about duty, about what we owe to each other,” Warren said. Eventually, she said, a student landed on the answer, saying, “We owe each other that everybody gets a turn,” a comment that fits into her rationale for running for president.

Warren was traveling with the Rev. Miniard Culpepper, the pastor at Boston’s Pleasant Hill Missionary Baptist Church, whom she referred to as a “spiritual adviser.”

Culpepper said he has known Warren since she ran for Senate in 2012, and he said he’s not worried about the perception that she’s lacking black support. “They’ll be there,” he said in a brief interview. “She’s just hitting her stride.”