From 17b79e4114c39765be05017de23c1a608e307ace Mon Sep 17 00:00:00 2001 From: Roberto Rosario Date: Thu, 10 Aug 2017 22:22:20 -0400 Subject: [PATCH] Call the index rebuild task the proper way. Signed-off-by: Roberto Rosario --- mayan/apps/document_indexing/views.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/mayan/apps/document_indexing/views.py b/mayan/apps/document_indexing/views.py index 872321162c..fe51c763d4 100644 --- a/mayan/apps/document_indexing/views.py +++ b/mayan/apps/document_indexing/views.py @@ -330,7 +330,9 @@ class RebuildIndexesView(FormView): def form_valid(self, form): for index in form.cleaned_data['indexes']: - task_rebuild_index(index_id=index.pk) + task_rebuild_index.apply_async( + kwargs=dict(index_id=index.pk) + ) messages.success(self.request, _('Index rebuild queued successfully.'))