Skip to content

Conversation

archie9211
Copy link
Contributor

@archie9211 archie9211 commented May 3, 2021

searches files on torrent-paradise.ml and return the torrent with most seeders

"https://torrent-paradise.ml/api/search?q=" + query)
torrents = r.json()
torrents = sorted(torrents, key=lambda i: i['s'], reverse=True)
torrent = torrents[0]
Copy link
Owner

@shivamdev-lgtm shivamdev-lgtm May 13, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This assumes only one torrent is returned by the api for the query but it can return multiple. Won't it make more sense if it shows the name of the torrents to the user and let the user decide what he/she wants to mirror instead of just assuming it to be the first one from the sorted list.. Maybe bot should reply with list of buttons showing the name of the torrents and clicking on it will trigger the mirror process

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants