Skip to content

Updated "Authentication System with Guard" Page #7215

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

Merged
merged 5 commits into from
Dec 13, 2016

Conversation

powerdan
Copy link
Contributor

@powerdan powerdan commented Dec 3, 2016

Added the (optional) createAuthenticatedToken() Method and dcoumented it.

Also added the braces to the no-argument Method supportsRememberMe.

Also removed the `` Operators in the FAQ section because the bacticks seems not to be resolved in a title on symfony.com


**createAuthenticatedToken(UserInterface $user, string $providerKey)**
If you are implementing the :class:`Symfony\\Component\\Security\\Guard\\GuardAuthenticatorInterface`
Method instead of extending the :class:`Symfony\\Component\\Security\\Guard\\AbstractGuardAuthenticator`,
Copy link
Member

Choose a reason for hiding this comment

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

"Method" should be removed.

Copy link
Member

Choose a reason for hiding this comment

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

we could add "class" before the comma

Method instead of extending the :class:`Symfony\\Component\\Security\\Guard\\AbstractGuardAuthenticator`,
you have to implement this method. This method will be called
after a successful authentication to create and return the token
for the user, which was supplied as the first argument.
Copy link
Member

Choose a reason for hiding this comment

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

"who" instead of "which"?

@powerdan
Copy link
Contributor Author

powerdan commented Dec 3, 2016

Thanks for the suggestions, i accepted them


**createAuthenticatedToken(UserInterface $user, string $providerKey)**
If you are implementing the :class:`Symfony\\Component\\Security\\Guard\\GuardAuthenticatorInterface`
instead of extending the :class:`Symfony\\Component\\Security\\Guard\\AbstractGuardAuthenticator`,
Copy link
Member

Choose a reason for hiding this comment

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

I think we should also add the word "class" after the class name.

@xabbuh
Copy link
Member

xabbuh commented Dec 3, 2016

👍 Looks perfect to me! Thanks for you work @powerdan!

Status: Reviewed

@powerdan
Copy link
Contributor Author

powerdan commented Dec 3, 2016

I just added the class word there. I also thinks its an good idea


**createAuthenticatedToken(UserInterface $user, string $providerKey)**
If you are implementing the :class:`Symfony\\Component\\Security\\Guard\\GuardAuthenticatorInterface`
class instead of extending the :class:`Symfony\\Component\\Security\\Guard\\AbstractGuardAuthenticator`
Copy link
Member

Choose a reason for hiding this comment

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

@powerdan Sorry about that but class that you added here should be reverted. GuardAuthenticatorInterface is an interface, but not a class. Though as Interface is already part of the name we shouldn't add the word "interface" instead of "class". We should only keep the one after AbstractGuardAuthenticator.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Youre absolutely right. It seems that i am kind of tired after that week.... (in berlin since monday)

Copy link
Member

Choose a reason for hiding this comment

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

I completely understand that. :)

**createAuthenticatedToken(UserInterface $user, string $providerKey)**
If you are implementing the :class:`Symfony\\Component\\Security\\Guard\\GuardAuthenticatorInterface`
instead of extending the :class:`Symfony\\Component\\Security\\Guard\\AbstractGuardAuthenticator`
class, you have to implement this method. This method will be called
Copy link
Member

Choose a reason for hiding this comment

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

I don't like the ... this method. This method ... repetition in this line. How could we reword it?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Changing it to ... this method. It will be called... seems pretty simple, but im not really happy with it. What does you people think?

Copy link
Member

Choose a reason for hiding this comment

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

... this method. It will be called... sounds completely valid to me.

@xabbuh
Copy link
Member

xabbuh commented Dec 13, 2016

Thank you @powerdan.

@xabbuh xabbuh merged commit d17b180 into symfony:2.8 Dec 13, 2016
xabbuh added a commit that referenced this pull request Dec 13, 2016
…, Daniel Werner)

This PR was merged into the 2.8 branch.

Discussion
----------

Updated "Authentication System with Guard" Page

Added the (optional) createAuthenticatedToken() Method and dcoumented it.

Also added the braces to the no-argument Method supportsRememberMe.

Also removed the `` Operators in the FAQ section because the bacticks seems not to be resolved in a title on symfony.com

Commits
-------

d17b180 Accepted Suggestions
cb3abf3 Accepted suggestions in the guard documentation
b2f20f4 Accepted suggestions in the guard documentation
33c0d35 Accepted suggestions in the guard documentation
f8e201f Update guard_authentication.rst
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants