Fix typo in extended related name

This commit is contained in:
Alexandre Iooss 2021-10-13 17:06:45 +02:00
parent cc3ba4a492
commit c317310dcf
3 changed files with 5 additions and 5 deletions

View file

@ -56,12 +56,12 @@ class CustomGalleryDetailView(DetailView):
# List owners
context['owners'] = []
for photo in context['photos']:
if photo.extented.owner not in context['owners']:
context['owners'].append(photo.extented.owner)
if photo.extended.owner not in context['owners']:
context['owners'].append(photo.extended.owner)
# Filter on owner
if 'owner' in self.kwargs:
context['photos'] = context['photos'].filter(extented__owner__id=self.kwargs['owner'])
context['photos'] = context['photos'].filter(extended__owner__id=self.kwargs['owner'])
return context