A United Nations committee agreed to adopt a softened version of a resolution on limiting government surveillance and the mass collection of personal data, after the U.S. and its allies invoked the need for effective intelligence-gathering to combat terrorism.

The General Assembly’s human rights committee today adopted by consensus the non-binding resolution, which invoked possible dangers posed to privacy rights by the mass collection of metadata, such as bulk records of phone calls gathered by the U.S. National Security Agency and other intelligence agencies.

The resolution stopped short of condemning metadata collection after the U.S. and its allies lobbied to remove language classifying it as “highly intrusive,” according to two UN diplomats involved in the negotiations who asked not to be named commenting on private consultations.

The Obama administration said that such intelligence-gathering is needed to fight terrorists such as Islamic State militants in Iraq and Syria and to address the threat of foreign fighters coming home to stage terror attacks in Europe or the U.S., the diplomats said.

That U.S. argument was backed by its fellow members in an intelligence cooperation agreement known as Five Eyes, they said. The other members are Australia, New Zealand, the U.K. and Canada.