mirror of
https://codeberg.org/hyperreal/admin-scripts
synced 2024-11-25 09:03:41 +01:00
fix: ensure no duplicate items
This commit is contained in:
parent
cce5fd87bf
commit
75ecc058ec
@ -47,7 +47,7 @@ if __name__ == "__main__":
|
||||
torrent_infohashes.append(torrent.get("hash")) # type: ignore
|
||||
|
||||
# Format the infohashes to have a \n at the end
|
||||
format_infohashes = [f"{infohash}\n" for infohash in torrent_infohashes]
|
||||
format_infohashes = set([f"{infohash}\n" for infohash in torrent_infohashes])
|
||||
|
||||
# Create a NamedTemporaryFile and write all infohashes to it, one per line
|
||||
with tempfile.NamedTemporaryFile() as ntf:
|
||||
|
Loading…
Reference in New Issue
Block a user