X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/a5d97184b87b72f8fb964c862af0f54f3ef788c1..df4e3c8b0d4dfa9ec6d16340465dc4ed0182a297:/src/annoy/models.py diff --git a/src/annoy/models.py b/src/annoy/models.py index 5b9009b0c..9ed724c0e 100644 --- a/src/annoy/models.py +++ b/src/annoy/models.py @@ -40,9 +40,9 @@ class Banner(models.Model): if hasattr(request, 'annoy_banner_exempt'): return cls.objects.none() - + if settings.DEBUG: - assert place in PLACES, "Banner place `{}` must be defined in annoy.places.".format(place) + assert place in PLACES, f"Banner place `{place}` must be defined in annoy.places." n = now() banners = cls.objects.filter( @@ -60,8 +60,8 @@ class Banner(models.Model): if Membership.is_active_for(request.user): banners = banners.filter(show_members=True) return banners - - + + class DynamicTextInsert(models.Model): paragraphs = models.IntegerField(_('pararaphs')) url = models.CharField(max_length=1024)