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

Fix sso warning #1258

Merged
merged 2 commits into from
Feb 8, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ exports[`Auth0APIClient logIn with credentials should call client.login 1`] = `
Object {
"nonce": undefined,
"realm": undefined,
"sso": undefined,
"state": undefined,
"username": "foo",
}
Expand All @@ -42,7 +41,6 @@ Object {
exports[`Auth0APIClient logIn with credentials should call popup.loginWithCredentials when redirect is false and sso is false 1`] = `
Object {
"nonce": undefined,
"sso": undefined,
"state": undefined,
"username": "foo",
}
Expand All @@ -51,7 +49,6 @@ Object {
exports[`Auth0APIClient logIn with credentials should call popup.loginWithCredentials when redirect is false and sso is true 1`] = `
Object {
"nonce": undefined,
"sso": undefined,
"state": undefined,
"username": "foo",
}
Expand All @@ -60,7 +57,6 @@ Object {
exports[`Auth0APIClient logIn with social/enterprise (without username and email) should call authorize when redirect===true 1`] = `
Object {
"nonce": undefined,
"sso": undefined,
"state": undefined,
}
`;
Expand All @@ -69,7 +65,6 @@ exports[`Auth0APIClient logIn with social/enterprise (without username and email
Object {
"nonce": undefined,
"owp": true,
"sso": undefined,
"state": undefined,
}
`;
Expand Down
6 changes: 4 additions & 2 deletions src/core/web_api/p2_api.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,11 @@ class Auth0APIClient {
popup: !opts.redirect,
popupOptions: opts.popupOptions,
nonce: opts.nonce,
state: opts.state,
sso: this.isUniversalLogin ? opts.sso : undefined
state: opts.state
};
if (this.isUniversalLogin && opts.sso !== undefined) {
this.authOpt.sso = opts.sso;
}
}

logIn(options, authParams, cb) {
Expand Down
3 changes: 1 addition & 2 deletions support/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,7 @@ <h1 class="navbar-brand">
email: 'johnfoo@gmail.com'
},
passwordlessMethod: 'code',
allowedConnections: ['email', 'acme', 'twitter'],
auth: { sso: true }
allowedConnections: ['email', 'acme', 'twitter']
};
function initLock() {
var lock = new Auth0Lock(clientId, domain, defaultOptions);
Expand Down