Fix resuming all torrents.

This commit is contained in:
Andrew Resch 2008-02-08 22:51:41 +00:00
parent eee68666ef
commit c7c1ea26f9
1 changed files with 2 additions and 2 deletions

View File

@ -323,7 +323,7 @@ class TorrentManager(component.Component):
torrent_was_paused = False
for key in self.torrents.keys():
try:
self.torrents[key].handle.pause()
self.torrents[key].pause()
torrent_was_paused = True
except:
log.warning("Unable to pause torrent %s", key)
@ -334,7 +334,7 @@ class TorrentManager(component.Component):
"""Resumes all torrents.. Returns True if at least 1 torrent is resumed"""
torrent_was_resumed = False
for key in self.torrents.keys():
if self.resume(key):
if self.torrents[key].resume():
torrent_was_resumed = True
else:
log.warning("Unable to resume torrent %s", key)