Skip to content

Commit 895cfba

Browse files
committed
fixed Undifined issue
1 parent 1fec16e commit 895cfba

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/web-components/src/components/notice-choice/notice-choice.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -677,7 +677,8 @@ class NoticeChoice extends StableSelectorMixin(LitElement) {
677677
}
678678

679679
if (this.doubleOptInCountries.includes(country)) {
680-
preText += ` <span part="double-opt-in-text">${content.mkDoubleOptInText}</span>`;
680+
const text = content?.mkDoubleOptInText || '';
681+
preText += text ? ` <span part="double-opt-in-text">${text}</span>` : '';
681682
}
682683

683684
// 4. permission/suppression logic

0 commit comments

Comments
 (0)