Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SDK-2708] Use configured domain for client assets download #2029

Merged
merged 6 commits into from
Sep 3, 2021

Conversation

stevehobbsdev
Copy link
Contributor

Changes

This PR reconfigures Lock to use the configured domain when constructing the URL to download the client assets file, instead of using cdn.[locality].auth0.com.

The change applies to:

  • Configuring Lock with an Auth0 domain: example.us.auth0.com
  • Custom domains: auth.custom-domain.com
  • Auth0 domain with __useTenantInfo: true in the config
  • Custom domain with __useTenantInfo: true in the config

Test coverage for these settings has been added.

Testing

  • This change adds unit test coverage
  • This change adds integration test coverage
  • This change has been tested on the latest version of the platform/language

Checklist

@stevehobbsdev stevehobbsdev added this to the v11.30.5 milestone Aug 26, 2021
@lgtm-com
Copy link
Contributor

lgtm-com bot commented Aug 26, 2021

This pull request introduces 1 alert and fixes 2 when merging 99c2fa2 into 1d3e7be - view on LGTM.com

new alerts:

  • 1 for Incomplete URL substring sanitization

fixed alerts:

  • 2 for Incomplete URL substring sanitization

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Aug 26, 2021

This pull request introduces 1 alert and fixes 2 when merging ddf3354 into 1d3e7be - view on LGTM.com

new alerts:

  • 1 for Incomplete URL substring sanitization

fixed alerts:

  • 2 for Incomplete URL substring sanitization

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Aug 27, 2021

This pull request introduces 1 alert and fixes 2 when merging 02687f6 into 1d3e7be - view on LGTM.com

new alerts:

  • 1 for Incomplete URL substring sanitization

fixed alerts:

  • 2 for Incomplete URL substring sanitization

@stevehobbsdev stevehobbsdev marked this pull request as ready for review August 27, 2021 10:44
@stevehobbsdev stevehobbsdev requested a review from a team as a code owner August 27, 2021 10:44
@lgtm-com
Copy link
Contributor

lgtm-com bot commented Aug 27, 2021

This pull request introduces 1 alert and fixes 2 when merging 1f04fcf into 1d3e7be - view on LGTM.com

new alerts:

  • 1 for Incomplete URL substring sanitization

fixed alerts:

  • 2 for Incomplete URL substring sanitization

joseluisdiaz
joseluisdiaz previously approved these changes Aug 30, 2021
Copy link
Member

@joseluisdiaz joseluisdiaz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

src/__tests__/core/index.test.js Show resolved Hide resolved
src/__tests__/core/index.test.js Outdated Show resolved Hide resolved
expect(mock.calls.length).toBe(1);

const model = mock.calls[0][1].toJS();
expect(model.tenantBaseUrl).toBe('https://auth.my-tenant.com/info-v1.js');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why the path differs in this one? what's the condition? you might want to reflect that in the test name

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I'm not sure of the history as to why this is. If you use a custom domain, the URL differs when using __useTenantInfo vs using an auth0.com domain. Just trying to keep and verify the same logic here.

src/__tests__/core/index.test.js Show resolved Hide resolved
src/__tests__/core/index.test.js Show resolved Hide resolved
@lgtm-com
Copy link
Contributor

lgtm-com bot commented Sep 2, 2021

This pull request introduces 1 alert and fixes 2 when merging 33a4c71 into 1d3e7be - view on LGTM.com

new alerts:

  • 1 for Incomplete URL substring sanitization

fixed alerts:

  • 2 for Incomplete URL substring sanitization

@stevehobbsdev stevehobbsdev merged commit 2dd24fa into master Sep 3, 2021
@stevehobbsdev stevehobbsdev deleted the sdk-2708/settings-url branch September 3, 2021 14:27
@stevehobbsdev stevehobbsdev mentioned this pull request Sep 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
review:small Small review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants