Module: deluge
Branch: master
Commit: 901d2d715c907fcb0c14b4dde5516bc85d19fb81

Author: Andrew Resch <[email protected]>
Date:   Fri Apr  9 13:05:02 2010 -0700

Fix #1222 do not try to set options on a torrent_id that is no longer in the 
session

---

 deluge/plugins/label/label/core.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/deluge/plugins/label/label/core.py 
b/deluge/plugins/label/label/core.py
index 0971db7..1bd52b8 100644
--- a/deluge/plugins/label/label/core.py
+++ b/deluge/plugins/label/label/core.py
@@ -269,7 +269,7 @@ class Core(CorePluginBase):
 
         #apply
         for torrent_id,label in self.torrent_labels.iteritems():
-            if label_id == label:
+            if label_id == label and torrent_id in self.torrents:
                 self._set_torrent_options(torrent_id , label_id)
 
         #auto add

-- 
You received this message because you are subscribed to the Google Groups 
"deluge-commit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/deluge-commit?hl=en.

Reply via email to