More API improvements

This commit is contained in:
Bofh 2021-02-11 20:08:05 +01:00
parent 15f47b63f4
commit 465da4ef0f
1 changed files with 7 additions and 0 deletions

View File

@ -117,12 +117,19 @@ div.item > div.links > div:nth-child(2) > a {
if acc_id == '*':
if False:
pass
elif action == 'update':
igmirror.update_allaccounts_async()
return echo(self, {'status': 'ok', 'message': 'All accounts update asyncronous started!'})
elif action == 'login':
igmirror.pixelfed_loginall_async()
return echo(self, {'status': 'ok', 'message': 'All accounts login asyncronous started!'})
elif action == 'logout':
igmirror.pixelfed_logoutall_async()
return echo(self, {'status': 'ok', 'message': 'All accounts logout asyncronous started!'})
else:
# make sure account name contains only safe characters
# i think IG usernames can only have this characters: