summaryrefslogtreecommitdiffstats
path: root/pyload/database/Storage.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyload/database/Storage.py')
-rw-r--r--pyload/database/Storage.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/pyload/database/Storage.py b/pyload/database/Storage.py
index 45ad18b2d..70932b55c 100644
--- a/pyload/database/Storage.py
+++ b/pyload/database/Storage.py
@@ -26,14 +26,12 @@ class StorageMethods(object):
return row[0]
else:
db.c.execute("SELECT key, value FROM storage WHERE identifier=?", (identifier,))
- d = {}
- for row in db.c:
- d[row[0]] = row[1]
- return d
+ return {row[0]: row[1] for row in db.c}
@style.queue
def delStorage(db, identifier, key):
db.c.execute("DELETE FROM storage WHERE identifier=? AND key=?", (identifier, key))
+
DatabaseBackend.registerSub(StorageMethods)