mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-04 15:38:43 +00:00
Fix loading the saved metadata when loading state with magnet uris
This commit is contained in:
parent
313c73c40c
commit
8d6bc283d0
2 changed files with 10 additions and 10 deletions
|
@ -2,6 +2,7 @@
|
||||||
==== Core ====
|
==== Core ====
|
||||||
* Fix deleting old .fastresume files with fresh configs
|
* Fix deleting old .fastresume files with fresh configs
|
||||||
* Fix files list when using magnet uris
|
* Fix files list when using magnet uris
|
||||||
|
* Fix loading the saved metadata when loading state with magnet uris
|
||||||
|
|
||||||
==== GtkUI ====
|
==== GtkUI ====
|
||||||
* Fix showing the 'Other' speed dialogs in Windows
|
* Fix showing the 'Other' speed dialogs in Windows
|
||||||
|
|
|
@ -350,17 +350,16 @@ class TorrentManager(component.Component):
|
||||||
options["move_completed_path"] = state.move_completed_path
|
options["move_completed_path"] = state.move_completed_path
|
||||||
options["add_paused"] = state.paused
|
options["add_paused"] = state.paused
|
||||||
|
|
||||||
if not state.magnet:
|
ti = self.get_torrent_info_from_file(
|
||||||
add_torrent_params["ti"] =\
|
os.path.join(get_config_dir(),
|
||||||
self.get_torrent_info_from_file(
|
"state", state.torrent_id + ".torrent"))
|
||||||
os.path.join(get_config_dir(),
|
if ti:
|
||||||
"state", state.torrent_id + ".torrent"))
|
add_torrent_params["ti"] = ti
|
||||||
|
elif state.magnet:
|
||||||
if not add_torrent_params["ti"]:
|
|
||||||
log.error("Unable to add torrent!")
|
|
||||||
return
|
|
||||||
else:
|
|
||||||
magnet = state.magnet
|
magnet = state.magnet
|
||||||
|
else:
|
||||||
|
log.error("Unable to add torrent!")
|
||||||
|
return
|
||||||
|
|
||||||
# Handle legacy case with storing resume data in individual files
|
# Handle legacy case with storing resume data in individual files
|
||||||
# for each torrent
|
# for each torrent
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue