In a closed-door meeting with evangelical leaders Monday night, President Donald Trump repeated his debunked claim that he had gotten "rid of" a law forbidding churches and charitable organizations from endorsing political candidates, according to recorded excerpts reviewed by NBC News.

In fact, the law remains on the books, after efforts to kill it in Congress last year failed.

But Trump cited this alleged accomplishment as one in a series of gains he has made for his conservative Christian supporters, as he warned, "You're one election away from losing everything that you've got," and said their opponents were "violent people" who would overturn these gains "violently."

Trump addressed the law and the upcoming midterms in private remarks Monday during a dinner with evangelical supporters at the White House after the press had left.

At stake in the November midterms, Trump told the audience, are all the gains he has made for conservative Christians.

"The level of hatred, the level of anger is unbelievable," he said. "Part of it is because of some of the things I've done for you and for me and for my family, but I've done them. … This Nov. 6 election is very much a referendum on not only me, it's a referendum on your religion, it's a referendum on free speech and the First Amendment."

If the GOP loses, he said, "they will overturn everything that we've done and they'll do it quickly and violently, and violently. There's violence. When you look at Antifa and you look at some of these groups — these are violent people."

The law that Trump says he got rid of is the so-called Johnson Amendment, a provision inserted into law in 1954 by then-senator and future President Lyndon Johnson of Texas, who was miffed that a conservative nonprofit group was helping his opponent.

The law says churches and charities "are absolutely prohibited from directly or indirectly participating in, or intervening in, any political campaign on behalf of (or in opposition to) any candidate for elective public office."

"Now one of the things I'm most proud of is getting rid of the Johnson Amendment," the president said. "That was a disaster for you."

The president doesn't have the power to repeal a law — only Congress can do that. The Supreme Court can also rule a law unconstitutional, but that has not happened in this case.

In May 2017, Trump signed an executive order that purported to ease enforcement of the Johnson Amendment. But experts — and the American Civil Liberties Union, which opposes repeal of the provision — say the Trump order was basically toothless.

"It does almost nothing," Gregory Magarian, a constitutional law professor at Washington University Law School.

Politifact, the nonpartisan fact-checking organization, rated Trump's claim that he had gotten rid of the Johnson Amendment "mostly false" when he first made it publicly in July 2017.

The law forbids religious organizations and other charities from formally endorsing candidates if they want to retain their federal tax exemption.

Trump's executive order instructs the Treasury Department not to "take any adverse action against any individual, house of worship, or other religious organization on the basis that such individual or organization speaks or has spoken about moral or political issues from a religious perspective, where speech of similar character has, consistent with law, not ordinarily been treated as participation or intervention in a political campaign on behalf of (or in opposition to) a candidate for public office … "

President Donald Trump speaks during a dinner for evangelical leaders in the State Dining Room of the White House, Monday, Aug. 27, 2018, in Washington. Alex Brandon / AP

In other words, religious organizations can express their religious views, as they always could — but still cannot formally participate in political campaigns.

Trump said to the religious leaders at the White House: "Now you're not silenced anymore. It's gone and there's no penalty anymore and if you like somebody or if you don't like somebody you can go out and say, 'This man is going to be great for evangelicals, or for Christianity or for another religion. This person is somebody that I like and I'm going to talk about it on Sunday."

In practice, there has been nothing stopping anyone from doing that. The Johnson Amendment doesn't prohibit individual speech, and it has rarely been enforced.

More than 2,000 mainly evangelical Christian clergy have deliberately violated the law since 2008 as a form of protest against it, but only one has been audited by the IRS, and none punished, according to the Alliance Defending Freedom, a pro-religious group.

A provision to overturn the amendment was included in last year's tax cut bill, but it was ultimately removed for procedural reasons.

Trump "doesn't have the legal authority to overturn the Johnson Amendment," Magarian said.

"You would think," Magarian added, "that the conservative religious leaders would get impatient at the continued repetition of that claim" that Trump has repealed it.

In the beginning of his private remarks to the evangelical leaders, Trump cited a comment he said was made by Robert Jeffress, a Southern Baptist leader who is one of his religious allies

"I had the great Robert Jeffress back there. Hello, Robert. Who said about me: He may not be the perfect human being, but he is the greatest leader for Christianity," Trump said to applause and laughter.

He added: "Hopefully I've proven that to be a fact in terms of the second part. Not the first part."

Later, Trump raised an issue that has become fodder for late night comedy shows.

"Little thing — Merry Christmas. You couldn't say Merry Christmas," Trump said. "I'm telling you — when I started running I used to talk about it and I hate to mention it in August, but I used to talk about it. They don't say Merry Christmas anymore."

Trump added, to applause: "They say Merry Christmas a lot right now. It's all changed. It's all changed."