diff options
author | lxf <sng@luxagraf.net> | 2021-01-06 15:48:14 -0500 |
---|---|---|
committer | lxf <sng@luxagraf.net> | 2021-01-06 15:48:14 -0500 |
commit | 534fcd39b1e8d24556d3bf110245a7373ee0eeb6 (patch) | |
tree | 96fa5d3bf4f5400a3855898ca4f41afcb5a40c75 /app | |
parent | 9a699c2f11a3ba440efae086b4303fdc55e5d97f (diff) |
fixed a bug in srcset fetch
Diffstat (limited to 'app')
-rw-r--r-- | app/media/models.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/media/models.py b/app/media/models.py index c266c4f..fe12a55 100644 --- a/app/media/models.py +++ b/app/media/models.py @@ -129,7 +129,7 @@ class LuxImage(models.Model): print(length) loopnum = 1 for size in self.sizes.all(): - srcset += "%s%s/%s_%s.%s %sw" % (settings.IMAGES_URL, self.pub_date.strftime("%Y"), self.image_name, size.name, self.image_ext, size.width) + srcset += "%s%s/%s_%s.%s %sw" % (settings.IMAGES_URL, self.pub_date.strftime("%Y"), self.image_name, size.slug, self.image_ext, size.width) if loopnum < length: srcset += ", " loopnum = loopnum+1 |