Skip to content

Commit

Permalink
Merge branch 'main' into TDW-2409-ad-value
Browse files Browse the repository at this point in the history
  • Loading branch information
bosco-ensemble committed Apr 17, 2024
2 parents 4ca9a48 + 23d6d8b commit 6e1e9f1
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions scripts/delayed.js
Original file line number Diff line number Diff line change
Expand Up @@ -755,3 +755,27 @@ const hasWeFevo = document.querySelector('a.we-fevo-btn');
if (hasWeFevo) {
injectWeFevoScript();
}

/**
* Loads Admiral script
*/
function loadAdmiral() {
const fetchScript = async () => {
try {
const response = await fetch(
'https://orchestrator-config-uat.pgatour.com/revops/admirial',
);
const content = await response.text();
const script = document.createElement('script');
script.type = 'text/javascript';
script.innerHTML = content;
script.id = 'admiral';
document.head.appendChild(script);
} catch (error) {
throw new Error('Error loading Admiral script: ', error);
}
};
fetchScript();
}

loadAdmiral();

0 comments on commit 6e1e9f1

Please sign in to comment.