mirror of
https://github.com/SickGear/SickGear.git
synced 2025-01-21 17:13:42 +00:00
Duplicate code found in rTorrent client module removed
This commit is contained in:
parent
69691f9d41
commit
06913ea517
1 changed files with 0 additions and 28 deletions
|
@ -75,34 +75,6 @@ class rTorrentAPI(GenericClient):
|
||||||
except:
|
except:
|
||||||
return False
|
return False
|
||||||
|
|
||||||
if not self.auth:
|
|
||||||
return False
|
|
||||||
|
|
||||||
if not result:
|
|
||||||
return False
|
|
||||||
|
|
||||||
try:
|
|
||||||
# Send magnet to rTorrent
|
|
||||||
torrent = self.auth.load_magnet(result.url, result.hash)
|
|
||||||
|
|
||||||
if not torrent:
|
|
||||||
return False
|
|
||||||
|
|
||||||
# Set label
|
|
||||||
if sickbeard.TORRENT_LABEL:
|
|
||||||
torrent.set_custom(1, sickbeard.TORRENT_LABEL.lower())
|
|
||||||
|
|
||||||
if sickbeard.TORRENT_PATH:
|
|
||||||
torrent.set_directory(sickbeard.TORRENT_PATH)
|
|
||||||
|
|
||||||
# Start torrent
|
|
||||||
torrent.start()
|
|
||||||
|
|
||||||
return True
|
|
||||||
|
|
||||||
except:
|
|
||||||
return False
|
|
||||||
|
|
||||||
def _add_torrent_file(self, result):
|
def _add_torrent_file(self, result):
|
||||||
filedata = None
|
filedata = None
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue