fix missing torrent_id in on_alert_state_changed

This commit is contained in:
Damien Churchill 2009-04-21 18:32:34 +00:00
parent cf0d155e99
commit fb85e76a1f
1 changed files with 2 additions and 1 deletions

View File

@ -747,7 +747,8 @@ class TorrentManager(component.Component):
def on_alert_state_changed(self, alert): def on_alert_state_changed(self, alert):
log.debug("on_alert_state_changed") log.debug("on_alert_state_changed")
try: try:
torrent = self.torrents[str(alert.handle.info_hash())] torrent_id = str(alert.handle.info_hash())
torrent = self.torrents[torrent_id]
except: except:
return return