won;t crash if trying to pause with no torrents

This commit is contained in:
Zach Tibbitts 2007-03-01 22:11:35 +00:00
parent f94eaa7b91
commit 230f2d151b

View file

@ -392,7 +392,10 @@ class DelugeGTK:
def start_pause(self, widget):
print "Pause btn clicked"
unique_id = self.get_selected_torrent()
self.manager.set_user_pause(unique_id, not self.manager.is_user_paused(unique_id))
try:
self.manager.set_user_pause(unique_id, not self.manager.is_user_paused(unique_id))
except KeyError:
pass
def build_summary_tab(self):
#Torrent Summary tab