X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/8d8fb6e63435faa5de2d07a52812f23b1796a29d..02fe6525fe7fa7c16d6e1dfe0ca040ac07d41325:/apps/picture/models.py diff --git a/apps/picture/models.py b/apps/picture/models.py index 1e27ce68e..c34b39a25 100644 --- a/apps/picture/models.py +++ b/apps/picture/models.py @@ -9,7 +9,7 @@ from django.template.loader import render_to_string from django.core.cache import get_cache from catalogue.utils import split_tags from django.utils.safestring import mark_safe -from slughifi import slughifi +from fnpdjango.utils.text.slughifi import slughifi from django.utils.translation import ugettext_lazy as _ from newtagging import managers @@ -148,7 +148,7 @@ class Picture(models.Model): for tag in catalogue.models.Tag.objects.filter(category='author'): pics_by_author[tag] = [] - for pic in pics: + for pic in pics.iterator(): authors = list(pic.tags.filter(category='author')) if authors: for author in authors: