-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[Security] fix Check if it has session before getSession() #42259
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
Conversation
Hey! I see that this is your first PR. That is great! Welcome! Symfony has a contribution guide which I suggest you to read. In short:
Review the GitHub status checks of your pull request and try to solve the reported issues. If some tests are failing, try to see if they are failing because of this change. When two Symfony core team members approve this change, it will be merged and you will become an official Symfony contributor! I am going to sit back now and wait for the reviews. Cheers! Carsonbot |
Hey! Oh no, it looks like you have made this PR towards a branch that is not maintained anymore. :/ Cheers! Carsonbot |
You've submitted your patch against the 5.4 branch although 5.2 should be the correct target. Can you please rebase your changes? Furthermore, can you please add a test covering your changes? |
7dcac82
to
3e040ef
Compare
The 5.2 version is no longer maintained. So consider upgrading to Symfony 5.3. And , I already add a test covering my changes. Please advise thanks. |
Don't this apply to |
src/Symfony/Component/Security/Http/Tests/EventListener/SessionLogoutListenerTest.php
Outdated
Show resolved
Hide resolved
src/Symfony/Component/Security/Http/Tests/EventListener/SessionLogoutListenerTest.php
Outdated
Show resolved
Hide resolved
Yeah, my comment did not age well. 😅 We've just release the final 5.2 release, so 5.3 is the correct target now. |
src/Symfony/Component/Security/Http/Tests/EventListener/SessionLogoutListenerTest.php
Outdated
Show resolved
Hide resolved
src/Symfony/Component/Security/Http/Tests/EventListener/SessionLogoutListenerTest.php
Show resolved
Hide resolved
src/Symfony/Component/Security/Http/Tests/EventListener/SessionLogoutListenerTest.php
Outdated
Show resolved
Hide resolved
Hi @mousezheng! Thanks for preparing this PR so quickly and even writing a test case. There are some mostly aesthetic suggestions for your test. Don't worry about too much about them, each library has its own unwritten testing practices :) |
@chalasr |
But that does not mean that we can leave it broken. If it needs to be fixed, we should fix it. |
But we can't include the fix in this PR, as that fix should target 4.4 and not 5.3 :) |
Thank you @mousezheng. |
Check if it has session before getSession(),for details, see issues#42258