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

Request the user to accept Terms&Policy before Sign Up #319

Merged
merged 2 commits into from
Aug 9, 2016
Merged

Conversation

lbalmaceda
Copy link
Contributor

@lbalmaceda lbalmaceda commented Aug 8, 2016

This affects database connections only. The dev must set the option on the builder first:

Lock lock = new Lock.Builder(account)
// ...
.setMustAcceptTerms(true)
.build();

When he completes the fields with valid data and press the submit button, a dialog will prompt asking for acceptance.

@lbalmaceda lbalmaceda added this to the 2.0.0-beta.4 milestone Aug 8, 2016
public void shouldNotSetTermsOfServiceURLWhenInvalidURL() {
Options options = new Options();
options.setAccount(auth0);
public void shouldNotSetTermsOfServiceURLWhenInvalidURL() throws Exception {
options.setTermsURL("an-invalid/url");
Copy link
Contributor

Choose a reason for hiding this comment

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

slightly OT but shouldn't this throw IAE instead of leaving a null value ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

If the given url it's not valid, the it will default to Auth0's terms/policy urls. I was trying to avoid throwing an exception at this point, and just warning the user that the default will be used on the LogCat. Anyway, I can add that change.

@hzalaz hzalaz merged commit c955cb5 into v2 Aug 9, 2016
@hzalaz hzalaz deleted the must-accept-terms branch August 9, 2016 19:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants