Skip to content
Snippets Groups Projects
Commit c9b45a08 authored by Sofia Papagiannaki's avatar Sofia Papagiannaki
Browse files

astakos: rename full-cleanup command to cleanup-full

parent a3f6b22b
No related branches found
No related tags found
No related merge requests found
...@@ -43,11 +43,11 @@ class Command(NoArgsCommand): ...@@ -43,11 +43,11 @@ class Command(NoArgsCommand):
def handle_noargs(self, **options): def handle_noargs(self, **options):
self.stdout.write('Cleanup sessions ...\n') self.stdout.write('Cleanup sessions ...\n')
call_command('cleanup') call_command('cleanup')
self.stdout.write('Cleanup session catalog ...\n') self.stdout.write('Cleanup session catalog ...\n')
engine = import_module(settings.SESSION_ENGINE) engine = import_module(settings.SESSION_ENGINE)
store = engine.SessionStore() store = engine.SessionStore()
tbd = (entry for entry in SessionCatalog.objects.all() \ tbd = (entry for entry in SessionCatalog.objects.all() \
if not store.exists(entry.session_key)) if not store.exists(entry.session_key))
for entry in tbd: for entry in tbd:
entry.delete() entry.delete()
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment