mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-02 22:48:40 +00:00
Fix adding torrents by URL.
This commit is contained in:
parent
67c7f9a80e
commit
d690e44194
2 changed files with 7 additions and 3 deletions
|
@ -215,8 +215,12 @@ class Core(
|
||||||
"""
|
"""
|
||||||
if save_path == "":
|
if save_path == "":
|
||||||
save_path = None
|
save_path = None
|
||||||
|
|
||||||
torrent_id = self.torrents.add(filename, filedump=filedump.data,
|
# Make sure we are sending a string to add()
|
||||||
|
if not isinstance(filedump, str):
|
||||||
|
filedump = filedump.data
|
||||||
|
|
||||||
|
torrent_id = self.torrents.add(filename, filedump=filedump,
|
||||||
save_path=save_path)
|
save_path=save_path)
|
||||||
|
|
||||||
# Run the plugin hooks for 'post_torrent_add'
|
# Run the plugin hooks for 'post_torrent_add'
|
||||||
|
|
|
@ -34,7 +34,7 @@
|
||||||
import sys
|
import sys
|
||||||
import deluge.SimpleXMLRPCServer as SimpleXMLRPCServer
|
import deluge.SimpleXMLRPCServer as SimpleXMLRPCServer
|
||||||
from SocketServer import ThreadingMixIn
|
from SocketServer import ThreadingMixIn
|
||||||
import xmlrpclib as xmlrpclib
|
import deluge.xmlrpclib as xmlrpclib
|
||||||
import threading
|
import threading
|
||||||
|
|
||||||
from deluge.log import LOG as log
|
from deluge.log import LOG as log
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue