person can be removed again, let async itemsort fail without exception

This commit is contained in:
j 2016-06-15 14:33:58 +02:00
parent fd9d3bdabf
commit af0e0cffe8

View file

@ -7,8 +7,11 @@ import models
@task(ignore_results=True, queue='default')
def update_itemsort(id):
p = models.Person.objects.get(pk=id)
p.update_itemsort()
try:
p = models.Person.objects.get(pk=id)
p.update_itemsort()
except models.Person.DoesNotExist:
pass
@task(ignore_results=True, queue='default')
def update_file_paths(id):