Facing scathing scrutiny after opening the 115th Congress with a secret midnight vote to gut the independent Office of Congressional Ethics, House Republicans on Tuesday abruptly withdrew the amendment before it could even go before the full chamber for a vote.

Bipartisan ethics watchdog groups led the charge, issuing blistering statements that attacked GOP lawmakers for undermining transparency and accountability in order to protect their own reputations.

“There has been such a backlash and so much tweeting and communication via public channels about this,” Viveca Novak of the Center for Responsive Politics told TPM. “They’re not just going to be able to ram it through with no repercussions.”

The OCE functions as the House’s independent ethics watchdog, investigating alleged ethics violations made by House members and their staff. The agency’s power is restricted to reviewing allegations, compiling a report and filing that report to the House Ethics Committee, which ultimately decides whether or not to conduct a formal investigation or issue sanctions.

Despite this relative toothlessness, the OCE enjoyed two key privileges: independence from Congress and the ability to make its reports public, providing crucial accountability. Both of those privileges would have gone out the window under the amendment proposed Monday night by House Judiciary Committee Chairman Bob Goodlatte (R-VA), which passed the GOP caucus by a vote of 119-74. Under Goodlatte’s measure, any OCE investigation could be stopped at the discretion of the Ethics Committee; the agency would have no spokesperson; and the agency would be banned from publicly releasing its findings without permission.

Craig Holman, a government affairs lobbyist for the watchdog group Public Citizen, said he was “exceedingly surprised” by the sudden appearance of Goodlatte’s measure.

“We had received assurances from the Republican conference that OCE was going to be reauthorized in the new Congress,” Holman told TPM. “A coalition of watchdog groups sent a letter to [House Minority Leader Nancy] Pelosi [(D-CA)] and [House Speaker Paul] Ryan [(R-WI)], and we were assured that OCE was going to be kept intact. It was just a midnight rule change last night that reversed everything so we were completely caught off guard.”

In November, Holman and representatives from other watchdog groups had put together a sweeping package of ethics reforms for the incoming Congress. Hoping that lawmakers would be inspired by President-elect Donald Trump’s “drain the swamp” campaign promise, the package draftees called on Congress to grant the OCE subpoena power, which it currently lacks, and to create a separate Office of Senate Ethics.

“We thought with the ‘drain the swamp’ message that there may be some efforts to strengthen ethics provisions not just for all government agencies in the next administration but for the next Congress as well,” said Scott Amey, general counsel for the Project on Government Oversight, which signed onto the ethics reform package.

Instead, a majority of House Republicans took the opposite tack, arguing that the OCE was overly aggressive in investigating members of Congress and that the agency’s public reports damaged the reputations of their subjects, whether or not it found ethics violations.

Appearing on ABC’s “Good Morning America” Tuesday morning, Trump’s special advisor Kellyanne Conway lamented the “overzealous” actions of the OCE.

“We don’t want people wrongly accused and we don’t want people mired in months if not years of ethical complaint review,” she said.

Amey argued those concerns don’t justify a complete defanging of the agency.

“That’s not a reason to throw the baby out with the bathwater,” he said. “There may be ways to improve on the system and also provide an increase of due process and protections for anyone accused of violating ethics rules, but it seems that the kneejerk reaction was to get rid of the whole office and make it a paper tiger.”

The OCE undeniably pushed the House Ethics Committee to take more action. According to Public Citizen’s Holman, the committee issued only five sanctions from the 1990s through 2006. Another five sanctions were issued from 2006-2008, after gambling lobbyist Jack Abramoff pled guilty for conspiring to bribe public officials to support certain pieces of legislation, an embarrassing scandal that destroyed the careers of several government officials.

Then in 2008, the incoming Democratic-controlled congress created the OCE to provide greater oversight.

“We immediately saw a four-fold increase in the number of actions taken by the House Ethics process because of OCE,” Holman said, pointing to some 20 sanctions the Ethic Committee issued from 2009-2014.

While some lawmakers grumbled at the OCE’s efforts, the agency received broad bipartisan, public support.

Judicial Watch, the watchdog group founded by conservative attorney and conspiracy theorist Larry Klayman and that is perhaps best known for dogging Hillary Clinton’s 2016 campaign through FOIA lawsuits, issued a statement Tuesday calling the OCE “the most significant ethics reform in Congress” and admonishing House Republicans for their “shameful,” “drive-by effort” to kill it.

Individual lawmakers joined the call against the rules change, and Trump fired off a pair of tweets asking if weakening the “unfair” agency should really be the “number one act and priority” of the new Congress.

Perhaps the most damning response came from the man whose felony crimes led to the OCE’s creation. Abramoff himself told Politico that “moving to diminish oversight is exactly the opposite of what Congress should be doing.”

Under this withering collective backlash, the House GOP called an emergency meeting on Tuesday to strike the language from its rule package. Just as suddenly as their ethics debacle emerged, it was gone.