[#2233] [lp:#1487704] Fix AttributeError in set_trackers with lt 1.0
This commit is contained in:
parent
123dd8f011
commit
acf4fc4193
|
@ -328,9 +328,12 @@ class Torrent(object):
|
||||||
if trackers == None:
|
if trackers == None:
|
||||||
trackers = []
|
trackers = []
|
||||||
for value in self.handle.trackers():
|
for value in self.handle.trackers():
|
||||||
tracker = {}
|
if lt.version_major == 0 and lt.version_minor < 15:
|
||||||
tracker["url"] = value.url
|
tracker = {}
|
||||||
tracker["tier"] = value.tier
|
tracker["url"] = value.url
|
||||||
|
tracker["tier"] = value.tier
|
||||||
|
else:
|
||||||
|
tracker = value
|
||||||
trackers.append(tracker)
|
trackers.append(tracker)
|
||||||
self.trackers = trackers
|
self.trackers = trackers
|
||||||
self.tracker_host = None
|
self.tracker_host = None
|
||||||
|
|
Loading…
Reference in New Issue