Change to ratio group setup to ensure everything is set correctly.

This commit is contained in:
Dean Gardiner
2013-08-02 01:40:31 +12:00
parent 7202fbf084
commit 0bdffc5036

View File

@@ -59,11 +59,16 @@ class rTorrent(Downloader):
group = self.rt.get_group(name)
if data.get('seed_ratio'):
# Explicitly set all group options to ensure it is setup correctly
group.set_upload('1M')
group.set_min(int(data.get('seed_ratio') * 100))
group.set_max(int(data.get('seed_ratio') * 100))
group.set_command('d.stop')
group.enable()
else:
# Reset group action
# Reset group action and disable it
group.set_command()
group.disable()
return True