minor performance improvements

This commit is contained in:
j 2019-08-01 17:00:02 +02:00
parent a149c7d7a0
commit 6706b93614

View file

@ -248,7 +248,7 @@ class Edit(models.Model):
clips_query = self.clip_query()
if clips_query['conditions']:
clips = clip.models.Clip.objects.find({'query': clips_query}, user)
items = [i['id'] for i in self.get_items(user).values('id')]
items = self.get_items(user).values('id')
clips = clips.filter(item__in=items)
else:
clips = clip.models.Clip.objects.filter(id=None)