Skip to content

Commit

Permalink
MWPW-147175 Support Extending window.adobeid (#2281)
Browse files Browse the repository at this point in the history
* MWPW-147175

* Update libs/utils/utils.js

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update libs/utils/utils.js

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update libs/utils/utils.js

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update libs/utils/utils.js

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update libs/utils/utils.js

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update libs/utils/utils.js

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Allow apps to override or extend window.adobeid

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: James Tsay <tsay@adobe.com>
Co-authored-by: James Tsay <65299136+TsayAdobe@users.noreply.github.com>
  • Loading branch information
4 people authored May 23, 2024
1 parent e74e21e commit a2d9267
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion libs/utils/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -790,7 +790,9 @@ export async function decorateFooterPromo(doc = document) {
let imsLoaded;
export async function loadIms() {
imsLoaded = imsLoaded || new Promise((resolve, reject) => {
const { locale, imsClientId, imsScope, env, base } = getConfig();
const {
locale, imsClientId, imsScope, env, base, adobeid,
} = getConfig();
if (!imsClientId) {
reject(new Error('Missing IMS Client ID'));
return;
Expand All @@ -812,6 +814,7 @@ export async function loadIms() {
clearTimeout(timeout);
},
onError: reject,
...adobeid,
};
const path = PAGE_URL.searchParams.get('useAlternateImsDomain')
? 'https://auth.services.adobe.com/imslib/imslib.min.js'
Expand Down

0 comments on commit a2d9267

Please sign in to comment.