Former Vice President Joe Biden apologized Saturday for remarks he made regarding his past work with segregationist lawmakers, acknowledging that they may have hurt some people.

“Was I wrong a few weeks ago to somehow give the impression to people that I was praising those men whom I successfully opposed time and again? Yes, I was,” he said during a speech in Sumter, South Carolina. “I regret it, and I’m sorry for any of the pain or misconception maybe I caused anybody.”

During last week’s Democratic primary debate, Sen. Kamala Harris (D-Calif.) called out Biden’s comments about finding common ground with former Sens. Herman Talmadge (D-Ga.) and James O. Eastland (D-Miss.), both of whom rejected desegregation.

Biden said Saturday that he hoped “that misstep” wouldn’t “define 50 years of my record for fighting for civil rights, racial justice in this country.”

“That just isn’t an honest assessment of my record, and I’m going to let my record and my character stand for itself and not be distorted or smeared,” he added.

Biden invoked the segregationists during a fundraising speech in New York City last month. He expressed concern about the current hyperpartisan climate in Washington and recalled sharing “some civility” with his colleagues.

However, Biden was criticized as being racially tone-deaf for stating that Eastland “never called me ‘boy,’ he always called me ‘son.’”

The candidate has since launched a full-throated defense of his past, telling CNN in an interview that aired Friday that his past was taken out of context. He said “wasn’t prepared” for Harris’ debate stage attack, during which she also revealed she was bused to school as a child and pressed Biden on his past opposition to federal busing programs.

Biden told the crowd in South Carolina that both he and the nation have evolved.

“America in 2019 is a very different place than the the 1970s, and that’s a good thing,” he said. “I’ve witnessed an incredible amount of change in this nation and I worked to make that change happen. And yes, I’ve changed also.”

“I’ve grown and I think it’s good to be able to grow, to progress,” he added.

The 2020 hopeful also touted his work with former President Barack Obama as a means of further defending his career.

“It was the honor of my lifetime to serve with a man who I believe was a great president, a historic figure, and most important to me ― a close friend,” he said. “I was vetted by he and 10 serious lawyers he appointed to go back and look at every single thing in my background ... and he selected me. I will take his judgment of my record, my character, and my ability to handle the job over anyone else’s.”

Ian Sams, Harris’ national press secretary, tweeted hours before Biden’s speech that all candidates’ records “will (and should be) scrutinized in this race.”