File tree Expand file tree Collapse file tree 1 file changed +10
-4
lines changed Expand file tree Collapse file tree 1 file changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -232,6 +232,12 @@ def product_thumbnail_xs(self, request):
232
232
image_url = first_image .image_xs .url
233
233
full_url = request .build_absolute_uri (image_url )
234
234
return full_url
235
+
236
+ if first_image and hasattr (first_image , 'image' ) and first_image .image :
237
+ image_url = first_image .image .url
238
+ full_url = request .build_absolute_uri (image_url )
239
+ return full_url
240
+
235
241
return None
236
242
237
243
@@ -394,7 +400,7 @@ def variant_thumbnail(self, request):
394
400
if first_image and hasattr (first_image , 'image' ) and first_image .image :
395
401
image_url = first_image .image .url
396
402
full_url = request .build_absolute_uri (image_url )
397
- return
403
+ return full_url
398
404
return None
399
405
400
406
def variant_thumbnail_xs (self , request ):
@@ -409,10 +415,10 @@ def variant_thumbnail_xs(self, request):
409
415
410
416
if self .product .images .exists ():
411
417
first_image = self .product .images .first ()
412
- if first_image and hasattr (first_image , 'image_xs ' ) and first_image .image_xs :
413
- image_url = first_image .image_xs .url
418
+ if first_image and hasattr (first_image , 'image ' ) and first_image .image :
419
+ image_url = first_image .image .url
414
420
full_url = request .build_absolute_uri (image_url )
415
- return
421
+ return full_url
416
422
return None
417
423
418
424
You can’t perform that action at this time.
0 commit comments