X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/75957f735219259d3b4bc361f80ccd3d7b92a0e9..2009fbf211892e7e25a8bf3c2fd934972b86db9a:/src/catalogue/models/source.py?ds=sidebyside diff --git a/src/catalogue/models/source.py b/src/catalogue/models/source.py index c678cad51..77b1a677b 100644 --- a/src/catalogue/models/source.py +++ b/src/catalogue/models/source.py @@ -25,7 +25,7 @@ class Source(models.Model): str(self.pk) old_self = type(self).objects.get(pk=self) except type(self).DoesNotExist: - old_name = u'' + old_name = '' old_netloc = self.netloc else: old_name = old_self.name @@ -37,7 +37,7 @@ class Source(models.Model): # and invalidate their cached includes. if old_name != self.name or old_netloc != self.netloc: for book in Book.objects.all(): - source = book.extra_info.get('source_url', '') + source = book.get_extra_info_json().get('source_url', '') if self.netloc in source or (old_netloc != self.netloc and old_netloc in source): book.clear_cache() return ret