Fix #545 use proper values in ratio calculation

This commit is contained in:
Andrew Resch 2008-10-23 16:52:09 +00:00
commit 1fbf983ff6
2 changed files with 77 additions and 76 deletions

View file

@ -1,6 +1,7 @@
Deluge 1.0.4 (In Development)
Core:
* Fix #560 force an int value for global max connections
* Fix #545 use proper values in ratio calculation
Deluge 1.0.3 (18 October 2008)
Core:

View file

@ -314,8 +314,8 @@ class Torrent:
else:
status = self.status
up = self.total_uploaded + status.total_payload_upload
down = status.total_done
up = status.all_time_upload
down = status.all_time_download
# Convert 'up' and 'down' to floats for proper calculation
up = float(up)
@ -417,7 +417,7 @@ class Torrent:
"paused": self.status.paused,
"progress": progress,
"next_announce": self.status.next_announce.seconds,
"total_payload_download": self.status.all_time_download,
"total_payload_download": self.status.total_payload_download,
"total_payload_upload": self.status.total_payload_upload,
"download_payload_rate": self.status.download_payload_rate,
"upload_payload_rate": self.status.upload_payload_rate,