diff options
author | luxagraf <sng@luxagraf> | 2021-02-22 11:02:21 -0500 |
---|---|---|
committer | luxagraf <sng@luxagraf> | 2021-02-22 11:02:21 -0500 |
commit | 97a532696024abba68d1c9a826369e5141a3a518 (patch) | |
tree | d801f6bce4dfbd97976aa96f6a60e33224f64d7f /app/media | |
parent | f02423e129970b1857c5a54e79c7046061ddd069 (diff) |
fixed a bug in image path vars
Diffstat (limited to 'app/media')
-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 83a2c7a..48fe9c9 100644 --- a/app/media/models.py +++ b/app/media/models.py @@ -147,7 +147,7 @@ class LuxImage(models.Model): def get_image_url_by_size(self, size="original"): if size == "original": - return self.image.url + return "%soriginal/%s/%s.%s" % (settings.IMAGES_URL, self.pub_date.strftime("%Y"), self.image_name, self.image_ext) if size == "admin_insert": return "images/%s/%s.%s" % (self.pub_date.strftime("%Y"), self.image_name, self.image_ext) else: |