Sen. Pat Toomey said Tuesday that it’s “completely unacceptable” for President Donald Trump to pressure state lawmakers to overturn Pennsylvania’s election result, a rare rebuke from an elected Republican as Trump continues his effort to subvert the will of the voters.

“It’s completely unacceptable and it’s not going to work and the president should give up trying to get legislatures to overturn the results of the elections in their respective states,” Toomey, Pennsylvania’s most prominent elected Republican, said in a phone interview. His comments came a day after it emerged that Trump called the Republican state House Speaker to seek help in undoing the outcome.

Toomey, one of fewer than 30 congressional Republicans to openly acknowledge Joe Biden’s victory, said he spoke with the president-elect by phone late last week, congratulated him, and discussed some of the few areas where they might be able to cooperate, such as on international trade.

“We had a very pleasant conversation,” Toomey said. He added that the outcome was “clear” and that “Joe Biden won the election.”

The call, and Toomey’s rejection of Trump’s latest maneuvers, stood out as an unusually direct Republican response to the president’s unprecedented attempts to thwart the election result. His stand put Toomey at odds with many fellow Republicans in Congress, the Pennsylvania state legislature, and some in the state’s congressional delegation, who have either sued to throw out Pennsylvania’s results — effectively disenfranchising the entire state — or who plan to oppose formal recognition of their own state’s outcome in Congress.

Their opposition to the outcome comes despite the Trump campaign’s failure to produce evidence of even a single Pennsylvania vote intentionally cast illegally.

» READ MORE: U.S. Supreme Court rejects GOP congressman’s last-minute effort to upend Pennsylvania’s election results

Gov. Tom Wolf, a Democrat, wrote “thank you” to Toomey on Twitter and Facebook.

“Pennsylvania had a fair and secure election. It’s on all of us to stand up against these attacks on our democracy,” Wolf posted.

Toomey, who faces less direct political pressure because he is not seeking reelection, has supported the vast majority of Trump’s policies. He wrote key parts of the failed attempt to repeal the Affordable Care Act and the GOP’s 2017 tax cuts. He has a two-decades-long record of backing conservative causes and supported Trump’s reelection.

Yet Toomey slammed Trump’s attempts to change the results after the Washington Post reported that Trump called Pennsylvania House Speaker Bryan Cutler (R., Lancaster) twice to seek help in doing so. Cutler told Trump the state legislature has no power to overturn Pennsylvania’s chosen slate of electors, a Cutler spokesperson said.

But Cutler was also among 64 GOP state lawmakers who wrote to Pennsylvania’s congressional delegation urging it to object to the state’s electoral slate when Congress formally receives the results in early January. At least one member of the state’s congressional delegation, Republican Rep. Scott Perry, told the Post he will indeed dispute the state’s Electoral College slate.

Toomey previously rejected that idea as well. He said he believes the moves by Trump and some Republicans could damage public faith in elections, pointing out that numerous judges and Trump’s own attorney general, Bill Barr, have found no evidence of widespread fraud.

» READ MORE: Fact-checking false claims about Pennsylvania’s presidential election by Trump and his allies

But Toomey also faulted Democrats and liberals for some of their actions.

“It’s also important to point out that this isn’t the only thing that has undermined people’s confidence in our government and our electoral system,” Toomey said. “A lot of Republicans across the commonwealth and across the country are sympathetic to some of the allegations being made by the president because they’ve witnessed the way he’s been treated for the last four years by the left and the press.”

He pointed to calls to impeach Trump before he was sworn in, “an attempt to impeach him over a phone call” with Ukraine’s president, and the so-called Steele dossier, a document of unsubstantiated rumors about Trump and Russia compiled by a former British intelligence officer. Some of the information was later cited in FBI applications to wiretap a Trump campaign adviser.

“The accumulation of these outrageous attacks leads people to wonder, ‘Well, what wouldn’t they do?’” Toomey said.

(The Democratic-led House impeached Trump for his efforts to leverage his office, and American security interests, to produce political dirt on Biden. Toomey has called Trump’s request to Ukraine’s president in the matter “inappropriate,” but said it wasn’t enough to throw out a duly elected president, and the GOP-controlled Senate acquitted him on the impeachment charges.)

» READ MORE: A Pennsylvania Republican gets a political boost from pushing Trump’s false election claims — with 2022 in sight

Trump on Tuesday continued his baseless allegations, tweeting his thanks to Cutler and “all others in Pennsylvania and elsewhere who fully understand what went on in the 2020 Election. It’s called total corruption!”

There is no evidence of any widespread voter fraud in Pennsylvania’s presidential election, which Biden won by 81,000 votes, nearly double Trump’s 2016 margin. Instead, the Trump campaign’s legal efforts have been aimed at disqualifying votes that all evidence shows were legitimately cast under rules it disagrees with. Every major case brought by the campaign has been rejected by judges, including some appointed by Trump.

Toomey noted that the president’s allegations have not been backed up in court.

Trump’s frustration with Democrats “doesn’t change the obligation of the president’s campaign to acknowledge that they have not been able to demonstrate that there’s been fraud, not on any significant scale,” Toomey said. “That has been determined by election officials, that has been determined by federal judges, that’s been determined by appellate court judges. That’s the opinion of the attorney general, who is a Donald Trump appointee. So in my view the outcome of the election is clear and that is that Joe Biden won the election. But I understand why people are upset and why they are inclined to listen to these allegations that have not been substantiated.”

He added, “It’s all very, very unhelpful to people’s confidence in our government.”