Skip to content

Commit 4b6a256

Browse files
committed
Fix thumbnail variable when no thumbnails available
1 parent 69c57c5 commit 4b6a256

File tree

4 files changed

+14
-5
lines changed

4 files changed

+14
-5
lines changed

CHANGELOG_de-DE.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
# 1.0.9
2+
3+
* BUGFIX Behebe Problem mit thumbnail-variable, wenn kein Thumbnail existiert
4+
15
# 1.0.8
26

37
* FEATURE Option zum Verbessern der Standard Gallery auf der Produktseite hinzugefügt

CHANGELOG_en-GB.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
# 1.0.9
2+
3+
* BUGFIX Fix thumbnail-variable, which occurs, when no thumbnail exists
4+
15
# 1.0.8
26

37
* FEATURE Added Option to fix ThumbnailSizes for the gallery on product page

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"thumbnail"
1212
],
1313
"description": "This plugins allows you to use variable thumbnails, without having them on storage.",
14-
"version": "1.0.8",
14+
"version": "1.0.9",
1515
"type": "shopware-platform-plugin",
1616
"license": "mit",
1717
"authors": [

src/Resources/views/storefront/utilities/thumbnail.html.twig

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,13 @@
33
{% else %}
44
{# FROSH: we are just removing max-width here, nothing more #}
55

6+
{# activate load per default. If it is not activated only a data-src is set instead of the src tag. #}
7+
{% if load is not defined %}
8+
{% set load = true %}
9+
{% endif %}
10+
611
{# uses cms block column count and all available thumbnails to determine the correct image size for the current viewport #}
712
{% if media.thumbnails|length > 0 %}
8-
{# activate load per default. If it is not activated only a data-src is set instead of the src tag. #}
9-
{% if load is not defined %}
10-
{% set load = true %}
11-
{% endif %}
1213

1314
{% if columns and sizes is not defined %}
1415
{# set image size for every viewport #}

0 commit comments

Comments
 (0)