Former House speaker Newt Gingrich said a Supreme Court battle over President Trump’s tax returns would help Republicans see if it was “worth it” to fight for the confirmation of Justice Brett M. Kavanaugh.

Gingrich, speaking Thursday at an event held by The Washington Post, said that if Democrats subpoena Trump’s tax returns during the next Congress, Trump will be “trapped into appealing to the Supreme Court.”

“And we’ll see whether or not the Kavanaugh fight was worth it,” he said.

The remark, which drew audible gasps from the audience, suggested Republicans like Gingrich are counting on Kavanaugh to protect the secrecy of Trump’s tax returns if Democrats take control of the House in November and begin aggressively investigating his finances. Trump has repeatedly refused to release his tax returns. Releasing them is a practice followed by previous presidents and the major parties’ White House nominees.

Kavanaugh was sworn in Oct. 6 after a bruising battle involving sexual misconduct allegations from multiple women. He denied the allegations. Senate Republicans, with just one defection, rallied behind him for a final vote of 50-48 in favor of confirmation.

Gingrich, a loyal supporter of Trump in 2016, said the odds favor Democrats in their battle to take control of the House, with Minority Leader Nancy Pelosi (D-Calif.) likely to become speaker.

“I think the odds are two out of three that she’ll be speaker and one out of three that [Republican leader] Kevin McCarthy will be,” he said.

Here’s a transcript of Gingrich’s “worth it” remark to Washington Post columnist Karen Tumulty:

Gingrich: This is a billionaire who has fought lawsuits his entire career, and he’s never noticed them. He doesn’t care. That’s why he has lawyers. So they can come at him from 100 levels — he’ll just hire 100 lawyers and say, you know, ‘call me when it’s over, I’ve got to go do other things, I’ll see you, I’m going to China or I’m going to campaign. But I don’t think he has any fear of the Democrats’ ability to investigate.

Tumulty: But he’s been raising that fear, out there on the camp —

Gingrich: Sure, because he wants everyone to go vote.

Tumulty: And what about if they subpoena his tax returns?

Gingrich: Then they’ll be trapped into appealing to the Supreme Court, and we’ll see whether or not the Kavanaugh fight was worth it.