mirror of
https://gitlab.com/allianceauth/allianceauth.git
synced 2026-02-06 07:06:19 +01:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c5b55283d1 | ||
|
|
d937d5b5d4 |
@@ -4,5 +4,5 @@ from __future__ import absolute_import, unicode_literals
|
|||||||
# Django starts so that shared_task will use this app.
|
# Django starts so that shared_task will use this app.
|
||||||
from .celeryapp import app as celery_app # noqa
|
from .celeryapp import app as celery_app # noqa
|
||||||
|
|
||||||
__version__ = '1.15.2'
|
__version__ = '1.15.3'
|
||||||
NAME = 'Alliance Auth v%s' % __version__
|
NAME = 'Alliance Auth v%s' % __version__
|
||||||
|
|||||||
@@ -71,7 +71,8 @@ def refresh_api(api):
|
|||||||
|
|
||||||
|
|
||||||
@app.task
|
@app.task
|
||||||
def refresh_user_apis(user):
|
def refresh_user_apis(pk):
|
||||||
|
user = User.objects.get(pk=pk)
|
||||||
logger.debug('Refreshing all APIs belonging to user %s' % user)
|
logger.debug('Refreshing all APIs belonging to user %s' % user)
|
||||||
apis = EveApiKeyPair.objects.filter(user=user)
|
apis = EveApiKeyPair.objects.filter(user=user)
|
||||||
for x in apis:
|
for x in apis:
|
||||||
@@ -98,7 +99,7 @@ def run_api_refresh():
|
|||||||
return
|
return
|
||||||
|
|
||||||
for u in User.objects.all():
|
for u in User.objects.all():
|
||||||
refresh_user_apis.delay(u)
|
refresh_user_apis.delay(u.pk)
|
||||||
|
|
||||||
|
|
||||||
@app.task
|
@app.task
|
||||||
|
|||||||
Reference in New Issue
Block a user