Skip to content

Commit

Permalink
TDW-2277 configured loadads to not be an async function
Browse files Browse the repository at this point in the history
  • Loading branch information
bosco-ensemble committed Apr 9, 2024
1 parent d2a760b commit 4cb9ab7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -713,7 +713,7 @@ async function loadPage(doc) {
// eslint-disable-next-line no-use-before-define
await loadLazy(doc);
// eslint-disable-next-line no-use-before-define
await loadAds(placeholders);
loadAds(placeholders);
// eslint-disable-next-line no-use-before-define
loadDelayed(doc);
}
Expand Down Expand Up @@ -1198,7 +1198,7 @@ async function OptanonWrapper() {
await sendAnalyticsPageEvent();
}

async function loadAds(placeholders) {
function loadAds(placeholders) {

Check failure on line 1201 in scripts/scripts.js

View workflow job for this annotation

GitHub Actions / build

'placeholders' is already declared in the upper scope on line 705 column 7
const isProd = window.location.hostname.endsWith(placeholders.hostname);

if (!isProd === 'this') {
Expand Down Expand Up @@ -1233,7 +1233,7 @@ async function loadAds(placeholders) {
if (document.querySelector('.marketing')) {
const marketingBlock = document.querySelector('.marketing');
decorateBlock(marketingBlock);
await loadBlock(marketingBlock);
loadBlock(marketingBlock);
}
}
}
Expand Down

0 comments on commit 4cb9ab7

Please sign in to comment.