Skip to content

Commit a0caa35

Browse files
committed
MC-3513: Empty Products Condition Results In 1px Height Products Content Type Wrapper On Stage
- Fixed bug
1 parent 59b1ad7 commit a0caa35

File tree

2 files changed

+3
-2
lines changed
  • app/code/Magento/PageBuilder/view/adminhtml/web

2 files changed

+3
-2
lines changed

app/code/Magento/PageBuilder/view/adminhtml/web/js/content-type/products/preview.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/code/Magento/PageBuilder/view/adminhtml/web/ts/js/content-type/products/preview.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ export default class Preview extends BasePreview {
6666

6767
if ((typeof data.conditions_encoded !== "string") || data.conditions_encoded.length === 0) {
6868
this.placeholderText(this.messages.EMPTY);
69+
6970
return;
7071
}
7172

@@ -83,7 +84,7 @@ export default class Preview extends BasePreview {
8384

8485
$.ajax(url, requestConfig)
8586
.done((response) => {
86-
if (typeof response.data !== "object" || typeof response.data.content === "undefined") {
87+
if (typeof response.data !== "object" || !Boolean(response.data.content)) {
8788
this.placeholderText(this.messages.EMPTY);
8889

8990
return;

0 commit comments

Comments
 (0)