feat: add initial seeding logic and separation between seeding from downloading

This commit is contained in:
Hachi-R
2024-11-04 03:13:17 -03:00
parent 83b7fb83ab
commit bd8974c7cb
6 changed files with 64 additions and 3 deletions

View File

@@ -107,6 +107,8 @@ class Handler(BaseHTTPRequestHandler):
elif data['action'] == 'kill-torrent':
torrent_downloader.abort_session()
torrent_downloader = None
elif data['action'] == 'start-seeding':
torrent_downloader.start_seeding(data['game_id'], data['magnet'], data['save_path'])
self.send_response(200)
self.end_headers()