mirror of https://github.com/rancher/dashboard.git
Changes following review
This commit is contained in:
parent
23ee18ef37
commit
1f68d5a825
|
|
@ -20,7 +20,6 @@ export default {
|
|||
|
||||
// The scopes in the redirect url are pulled out and reapplied, however this does not work for dex (a decoded space separator)
|
||||
const scopes = redirectAsUrl.searchParams.get(`scope`); // This decodes it
|
||||
const scopesArray = scopes.split(' ');
|
||||
|
||||
// redirectTo mangles the different scopes together incorrectly, and we're supply our own mangled version anyway, so nuke
|
||||
redirectAsUrl.searchParams.delete('scope');
|
||||
|
|
@ -28,8 +27,9 @@ export default {
|
|||
this.redirectOpts = {
|
||||
provider: this.name,
|
||||
redirectUrl: redirectAsUrl.toString(),
|
||||
scopes: scopesArray,
|
||||
scopesJoinChart: ' ',
|
||||
|
||||
scopes: scopes.split(' '), // Put it in the format expcted by the `redirectTo` action
|
||||
scopesJoinChar: ' ',
|
||||
|
||||
nonce: baseNonce,
|
||||
persistNonce: {
|
||||
|
|
|
|||
|
|
@ -242,7 +242,7 @@ export const actions = {
|
|||
let url = removeParam(redirectUrl, GITHUB_SCOPE);
|
||||
|
||||
const params = {
|
||||
[GITHUB_SCOPE]: scopes.join(opt.scopesJoinChart || ','), // Some providers won't accept comma separated scopes
|
||||
[GITHUB_SCOPE]: scopes.join(opt.scopesJoinChar || ','), // Some providers won't accept comma separated scopes
|
||||
[GITHUB_NONCE]: encodedNonce
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue