In a battle that cut across partisan lines, Montana’s lone congressman, Republican Steve Daines, voted Wednesday to support an amendment that would have curtailed some spying activities by the U.S. government.

The amendment, pushed by Michigan Reps. Justin Amash, a Republican, and John Conyers, a Democrat, would have ended the National Security Agency’s authority to tap the phones and email accounts of Americans not under criminal investigation.

The NSA’s work has been under much scrutiny since former contractor Edward Snowden revealed that the federal agency tracks nearly all communications by Americans.