The House voted unanimously, 419-0, this afternoon to update old tech federal technology laws to provide better privacy protections for Americans’ old emails from unwarranted government searches.

The Email Privacy Act, HB 699, updates the 1986 Electronic Communications Privacy Act to correct a significant gap in Fourth Amendment protections of citizens’ communications. The old law determined that emails or stored communications held by a third-party provider (like Google) were no longer subject to warrants in order for authorities to access their contents after 180 days. Law enforcement or investigatory agencies could just get subpoenas and go directly to the third-party storage systems to demand copies of the contents.

The legislation that passed today closes that loophole and requires actual warrants, but it’s still not going to be quite the same as when a law enforcement agency runs out to get a warrant to search your house. HB 699 gives law enforcement agencies 10 days (and other government entities three days) to inform the person whose e-mails or communications they had collected that they had done so. And authorities may request even further delays. So, when the police come and search your house, you know it right then. When they serve a warrant to a third-party email service, you might not find out for a few days. This was a carve-out in response to law enforcement and government agency fears that suspects would delete emails when the warrant was administered. It does also permit authorities, for a limited time, to gag the third-party providers from telling anybody (like the suspect) about the warrant.

(CORRECTION: Apparently the LEO groups got even more of their way in negotiations. The mandate that the authorities inform the subjects who have had their emails searched was actually excised from the bill before this vote. My mistake. The text remained in the formal summary of the legislation but not in the actual text. It leaves third party-providers with control over whether to inform subjects of searches, unless they’ve been gagged. Apologies for any confusion)

Exceptions aside, it’s certainly a much better system than we have now. The House version was sponsored by Reps. Kevin Yoder (R-Kansas) and Jared Polis (D-Colo.) and had many, many bipartisan sponsors. Now it’s going to head over to the Senate, where there might be a tougher fight, but we’ll have to see. The Senate version of the privacy bill has bipartisan co-sponsors as well, Patrick Leahy (D-Vermont) and Mike Lee (R-Utah). It has additional co-sponsors on the Senate side across the political spectrum from John Cornyn (R-Texas) to Dick Durbin (D-Ill.). Sen. Ted Cruz signed on as a co-sponsor last year. But the Senate version of the bill doesn’t have the overwhelming number of co-sponsors at this point that the House version did (314!) when it passed today. Some tech privacy activists are worried that the Senate will drag its feet in order to please critics within federal agencies and stop reforms from passing. Read more about these concerns here.