This repository was archived by the owner on Feb 12, 2025. It is now read-only.
PR for ES-1843#37
Open
mathiasconradt wants to merge 1 commit into
Open
Conversation
zxan1285
suggested changes
Sep 12, 2019
| window.env.userUrl + '?', | ||
| 'response_type=code', | ||
| '&scope=openid%20profile', | ||
| '&scope=' + encodeURIComponent(this.state.connection.options.scope), |
Contributor
There was a problem hiding this comment.
this.state.connection does not update on _save. So you have to re-open modal dialog to update the URL.
I'd suggest this:
var connection = this.state.connectionForm && this.state.connectionForm.getConnection() || this.state.connection;
return [
window.env.userUrl + '?',
'response_type=code',
'&scope=' + encodeURIComponent(connection.options.scope),
'&client_id=' + window.env.masterClientId,
'&connection=' + this.state.connection.name,
'&redirect_uri=' + window.env.manageUrl + '/tester/callback?connection=' + this.state.connection.name
].join('');
Author
There was a problem hiding this comment.
I have no way to really test this properly, I have no local test environment. I also am not familiar with this code base of the extension. Please consider my suggestion just as pseudo-code then :)
Happy to go with your suggestion if it works, as I don't have a way to test it. I trust a product engineer here more than my own code.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
✏️ Changes
The "Try" button of a custom social connection ignored the scope configuration entirely, because it was hardcoded. This should fix it, but please review, I wasn't able to deploy/test this extension anywhere. This PR is based on looking at the code.
📷 Screenshots
See https://auth0team.atlassian.net/servicedesk/customer/portal/34/ESD-1843
🔗 References
See https://auth0team.atlassian.net/servicedesk/customer/portal/34/ESD-1843
🎯 Testing
See https://auth0team.atlassian.net/servicedesk/customer/portal/34/ESD-1843
Configure a custom social connection and change the default scope configuration. The scopes should not be ignored when running the "Try" command.
Before, it was hardcoded as 'openid profile' and ignoring any additional scopes set in the configuration.
✅🚫 This change has been tested in a Webtask
✅🚫 This change has unit test coverage
✅🚫 This change has integration test coverage
✅🚫 This change has been tested for performance
🚀 Deployment
✅🚫 This can be deployed any time
🎡 Rollout
In order to verify that the deployment was successful we will …
🔥 Rollback
We will rollback if …
📄 Procedure
🖥 Appliance
Please review carefully, I wasn't able to deploy/test this extension anywhere. This PR is based on looking at the code.