Skip to content

Commit

Permalink
Merge branch 'stage' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
Blainegunn authored Mar 14, 2024
2 parents 76e82aa + 56236a6 commit f648d1b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion libs/blocks/caas-marquee/caas-marquee.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

/* eslint-disable no-shadow, consistent-return, max-len, quote-props, prefer-const */
import { createTag, getConfig, loadMartech } from '../../utils/utils.js';

Expand Down Expand Up @@ -812,8 +813,10 @@ export default async function init(el) {
if (window.alloy_pageView) {
// eslint-disable-next-line camelcase, no-undef
const sent = await alloy_pageView.sent;
if (sent.destinations[0].segments) {
if (sent?.destinations[0]?.segments) {
event = { detail: { type: 'pageView', result: { destinations: sent.destinations } } };
} else {
return loadFallback(marquee, metadata);
}
} else {
event = await waitForEventOrTimeout('alloy_sendEvent', ALLOY_TIMEOUT, new Event(''));
Expand Down

0 comments on commit f648d1b

Please sign in to comment.