summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarcos Pinto <markybob@dipconsultants.com>2007-10-23 03:26:28 +0000
committerMarcos Pinto <markybob@dipconsultants.com>2007-10-23 03:26:28 +0000
commit1c1398cddb1a32ea45109809238c8a447d773402 (patch)
tree9b66ce939613cb29833c2c4bb95eba5ea2c9b756
parent6520d43f69a9882c957aae2ae339eb0e2a059a5a (diff)
downloaddeluge-1c1398cddb1a32ea45109809238c8a447d773402.tar.gz
deluge-1c1398cddb1a32ea45109809238c8a447d773402.tar.bz2
deluge-1c1398cddb1a32ea45109809238c8a447d773402.zip
catch attributeerror to fix upgrade issue
-rw-r--r--src/core.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/core.py b/src/core.py
index 964414fc3..c5acf1bdc 100644
--- a/src/core.py
+++ b/src/core.py
@@ -315,9 +315,12 @@ class Manager:
# Save the uploaded data from this session to the existing upload memory
for unique_ID in self.unique_IDs.keys():
# self.get_core_torrent_state purposefully not cached.
- self.unique_IDs[unique_ID].uploaded_memory = \
+ try:
+ self.unique_IDs[unique_ID].uploaded_memory = \
self.unique_IDs[unique_ID].initial_uploaded_memory + \
self.get_core_torrent_state(unique_ID, False)['total_upload']
+ except AttributeError:
+ self.unique_IDs[unique_ID].initial_uploaded_memory = 0
# Preference management functions