summaryrefslogtreecommitdiffstats
path: root/module/database/StorageDatabase.py
diff options
context:
space:
mode:
authorGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2011-12-22 23:45:38 +0100
committerGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2011-12-22 23:45:38 +0100
commit958bf611f5d9d117f19f824990ec6fd6b537e967 (patch)
tree558cb45fa61b1738629dff9727c028badccd9990 /module/database/StorageDatabase.py
parentsome bugfixes (diff)
downloadpyload-958bf611f5d9d117f19f824990ec6fd6b537e967.tar.xz
accountmanager v2, delete your accounts.conf and re-enter them in pyload,
new nice debug functions, try core.shell() and core.breakpoint()
Diffstat (limited to 'module/database/StorageDatabase.py')
-rw-r--r--module/database/StorageDatabase.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/module/database/StorageDatabase.py b/module/database/StorageDatabase.py
index 3ed29625f..ffaf51763 100644
--- a/module/database/StorageDatabase.py
+++ b/module/database/StorageDatabase.py
@@ -16,11 +16,10 @@
@author: mkaay
"""
-from module.database import style
-from module.database import DatabaseBackend
+from module.database import DatabaseBackend, queue
class StorageMethods():
- @style.queue
+ @queue
def setStorage(db, identifier, key, value):
db.c.execute("SELECT id FROM storage WHERE identifier=? AND key=?", (identifier, key))
if db.c.fetchone() is not None:
@@ -28,7 +27,7 @@ class StorageMethods():
else:
db.c.execute("INSERT INTO storage (identifier, key, value) VALUES (?, ?, ?)", (identifier, key, value))
- @style.queue
+ @queue
def getStorage(db, identifier, key=None):
if key is not None:
db.c.execute("SELECT value FROM storage WHERE identifier=? AND key=?", (identifier, key))
@@ -42,7 +41,7 @@ class StorageMethods():
d[row[0]] = row[1]
return d
- @style.queue
+ @queue
def delStorage(db, identifier, key):
db.c.execute("DELETE FROM storage WHERE identifier=? AND key=?", (identifier, key))