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

Improve wording of auth strategy mode/default #3131

Merged
merged 2 commits into from May 21, 2016
Merged

Improve wording of auth strategy mode/default #3131

merged 2 commits into from May 21, 2016

Conversation

ghost
Copy link

@ghost ghost commented Apr 29, 2016

I found this wording confusing, and noticed other people have as well (e.g. dwyl/hapi-auth-jwt2#137 ). I think the proposed update better reflects when server.auth.strategy sets a default strategy for routes.

I found this wording confusing, and noticed other people have as well (e.g. dwyl/hapi-auth-jwt2#137 ).  I think the proposed update better reflects when `server.auth.strategy` sets a default strategy for routes.
@Marsup
Copy link
Contributor

Marsup commented Apr 29, 2016

Not sure it helps since the default is already false.

@ghost
Copy link
Author

ghost commented Apr 29, 2016

The original wording makes it sound like the strategy will only become the default auth for routes if required or true is specified as the mode. The reality is that when anything other than false is specified for the mode, the strategy will be set as the default strategy for routes.

@geek
Copy link
Member

geek commented Apr 29, 2016

https://github.com/hapijs/hapi/blob/master/lib/auth.js#L69-L71

We definitely can clarify the wording... can you add in that if you do set it to true the auth mode will be set to required

@ghost
Copy link
Author

ghost commented Apr 29, 2016

I misunderstood you initially @Marsup . Pushed another commit to clarify further based on your guys' suggestions.

@hueniverse hueniverse added the documentation Non-code related changes label May 21, 2016
@hueniverse hueniverse self-assigned this May 21, 2016
@hueniverse hueniverse merged commit 4657e34 into hapijs:master May 21, 2016
hueniverse added a commit that referenced this pull request May 21, 2016
@lock
Copy link

lock bot commented Jan 9, 2020

This thread has been automatically locked due to inactivity. Please open a new issue for related bugs or questions following the new issue template instructions.

@lock lock bot locked as resolved and limited conversation to collaborators Jan 9, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Non-code related changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants