Autostart torrent fix
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Michel Roux 2021-07-11 16:58:56 +02:00
parent a7c39054b1
commit 54042c6cd9
1 changed files with 2 additions and 1 deletions

View File

@ -248,8 +248,9 @@ def admin_edit(link_id=None):
if title.folder.path is not None and title.folder.path != '':
download_url = link.link.replace('/view/', '/download/') + '.torrent'
torrent_path = '%s/%s' % (title.folder.path, title.name)
torrent = transmission.add_torrent(download_url, download_dir=torrent_path, paused=False)
torrent = transmission.add_torrent(download_url, download_dir=torrent_path)
transmission.move_torrent_data(torrent.id, torrent_path)
transmission.start_torrent(torrent.id)
return redirect(url_for('admin'))