8000 Fix misleading TokenInterface docblock by giosh94mhz · Pull Request #12596 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

Fix misleading TokenInterface docblock #12596

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

Closed

Conversation

giosh94mhz
Copy link
Contributor
Q A
Bug fix? no
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets
License MIT
Doc PR

I've found the docblock for TokenInterface::getUser misleading. By reading it I've written something like:

$username = (string) $token->getUser();

This actually doesn't work, since UserInterface doesn't implements __toString and I have some instance of AdvancedUser (coming from InMemory provider).

If the token always return a UserInterface or string, then my fix is ok.

@giosh94mhz
Copy link
Contributor Author

Sorry, I've forgot to set the correct branch, which is 2.3. I close this one and recreate on the correct branch.

@giosh94mhz giosh94mhz closed this Nov 28, 2014
@giosh94mhz giosh94mhz deleted the misleading_token_interface_docblock branch December 1, 2014 09:23
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.

1 participant
0