-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Update expressions.rst #12132
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
Update expressions.rst #12132
Conversation
@@ -56,7 +56,9 @@ Additionally, you have access to a number of functions inside the expression: | |||
Returns ``true`` if the user is authenticated via "remember-me" or authenticated | |||
"fully" - i.e. returns true if the user is "logged in". | |||
``is_anonymous`` | |||
Equal to using ``IS_AUTHENTICATED_ANONYMOUSLY`` with the ``isGranted()`` function. | |||
Returns ``true`` if the user is anonymous. That is, the firewall confirms that it | |||
does not know this user's identity. This is different from ``IS_AUTHENTICATED_ANONYMOUSLY``, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about renaming it to „IS_AUTHENTICATED_OR_ANONYMOUSLY“ to make it more clear and understandable?
cc @chalasr
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, but that seems like a topic for its own PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Absolutely this must be implemented int the code base first 👌🏻
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @chalasr 👍
Could you approve this PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not ready yet! This PR is correct for lower versions anyways
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should apply on 3.4 if I'm not mistaken
Clarify the difference between the `is_anonymous` function and `IS_AUTHENTICATED_ANONYMOUSLY`.
Thank you Kevin. |
This PR was submitted for the 4.3 branch but it was merged into the 3.4 branch instead (closes #12132). Discussion ---------- Update expressions.rst Clarify the difference between the `is_anonymous` function and `IS_AUTHENTICATED_ANONYMOUSLY`. This fixes #11950. Commits ------- 6df9898 Update expressions.rst
Clarify the difference between the
is_anonymous
function andIS_AUTHENTICATED_ANONYMOUSLY
.This fixes #11950.