UPDATE: The USA Freedom Act passed the House on a vote of 303-121.

Unhappy with last-minute changes made to a bill designed to end the National Security Agency's bulk collection of American's phone and Internet records, Rep. Justin Amash voted against the bill.

The Michigan congressman, who was an original cosponsor of the USA Freedom Act, said he was “proud” of the work he and others did to promote the bill, but that he could not support the draft legislation as it is currently written.

“This morning's bill maintains and codifies a large-scale, unconstitutional domestic spying program,” Amash wrote on his Facebook page. “It claims to end bulk collection' of Americans' data only in a very technical sense: The bill prohibits the government from, for example, ordering a telephone company to turn over all its call records every day.”

Amash said that the bill, which was originally drafted by Rep. Jim Sensenbrenner, R-Wis., was “so weakened” by behind-the-scenes negotiations that it allows the government to order large swaths of American phone records “without probable cause.”

For example, the government could order AT&T to turn over all phone records for a particular area code or for “phone calls made east of the Mississippi,” according to Amash.

The current bill also extends the Patriot Act’s controversial section 215, which allows for the bulk collection of data, until 2017. The original bill expired that section in 2015.

The bill does still include some provisions that improve current law, including a requirement that the secret Foreign Intelligence Surveillance Court, which approves surveillance requests, publish its significant opinions for the public to see. The bill also allows, without a requirement, the FISC to appoint lawyers to argue on Americans’ behalf.

Amash called out President Obama and House Permanent Select Committee Chairman Mike Rogers, R-Mich., for refusing “to accept consensus reforms that will keep our country safe while upholding the Constitution.” Amash wrote that the gutted bill “mocks” the American governmental process.

“The American people demand that the Constitution be respected, that our rights and liberties be secured, and that the government stay out of our private lives,” Amash continued. “Fortunately, there is a growing group of representatives on both sides of the aisle who get it.

“We will succeed,” Amash concluded.