[Core] Fix placement of self.state in torrent.py

* Need to be created earlier as set_options calls update_state
This commit is contained in:
Calum Lind 2015-09-29 23:09:11 +01:00
parent f9b7892976
commit 244ae878c9

View file

@ -141,6 +141,9 @@ class Torrent(object):
# Store the magnet uri used to add this torrent if available
self.magnet = magnet
# Torrent state e.g. Paused, Downloading, etc.
self.state = None
# Holds status info so that we don't need to keep getting it from lt
self.status = self.handle.status()
@ -191,7 +194,6 @@ class Torrent(object):
self.statusmsg = "OK"
# The torrents state
self.state = None
self.update_state()
# The tracker status