summaryrefslogtreecommitdiffstats
path: root/pyload/AccountManager.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyload/AccountManager.py')
-rw-r--r--pyload/AccountManager.py12
1 files changed, 2 insertions, 10 deletions
diff --git a/pyload/AccountManager.py b/pyload/AccountManager.py
index 814c08615..7820d42f6 100644
--- a/pyload/AccountManager.py
+++ b/pyload/AccountManager.py
@@ -61,7 +61,6 @@ class AccountManager:
def loadAccounts(self):
"""loads all accounts available from db"""
-
for info, password, options in self.core.db.loadAccounts():
# put into options as used in other context
options = json.loads(options) if options else {}
@@ -108,7 +107,7 @@ class AccountManager:
account.scheduleRefresh()
self.saveAccounts()
- self.sendChange(plugin, loginname)
+ self.core.eventManager.dispatchEvent("account:updated", account.toInfoData())
return account
@lock
@@ -134,11 +133,7 @@ class AccountManager:
@lock
def getAllAccounts(self, uid):
- """ Return account info, refresh afterwards if needed
-
- :param refresh:
- :return:
- """
+ """ Return account info for every visible account """
# filter by owner / shared, but admins see all accounts
accounts = []
for plugin, accs in self.accounts.iteritems():
@@ -151,6 +146,3 @@ class AccountManager:
for p in self.accounts.itervalues():
for acc in p:
acc.getAccountInfo(True)
-
- def sendChange(self, plugin, name):
- self.core.eventManager.dispatchEvent("account:updated", plugin, name) \ No newline at end of file