(CNN) The US Secret Service says it will stop automatically deleting visitor logs for agencies within the White House complex while a lawsuit seeking the records is pending, according to a court filing late Monday.

Last week, government watchdog group Public Citizen filed suit in federal court, asking a judge to force the Secret Service turn over the logs for four separate agencies within the White House complex: the Office of Management and Budget, the Office of Science and Technology Policy, the Office of National Drug Control Policy and the US Council on Environmental Quality.

Normally, after a visit to the complex is complete, the Secret Service has no "continuing interest" to keep the visitor records, known as WAVES, so the information is transferred back to the White House Office of Records Management and deleted from the system, Justice Department attorneys said in a court filing

But for purposes of this lawsuit, Secret Service assured the judge the records will be preserved.

"Although not necessary to preserve the requested records, the Secret Service has stated that it will retain copies of all (visitor) data during the pendency of this litigation, and Secret Service has suspended auto-delete functions," DOJ attorneys wrote. Therefore, "because there is no danger of records not being preserved, (Public Citizen) is not suffering any harm, let alone irreparable harm."

Read More