-
Notifications
You must be signed in to change notification settings - Fork 108
Add IdentityHelper::getIdentity() #767
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
base: 4.x
Are you sure you want to change the base?
Conversation
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.
Pull request overview
This PR adds a new getIdentity() method to the IdentityHelper class that returns the identity instance directly, allowing users to access the full identity object rather than just its data. It also improves the documentation for the existing get() method.
Changes:
- Added
getIdentity()method to return theIdentityInterfaceinstance - Enhanced documentation for the
get()method to clarify its behavior - Added a test case for the new
getIdentity()method
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| src/View/Helper/IdentityHelper.php | Adds the new getIdentity() method and improves docblock for get() method |
| tests/TestCase/View/Helper/IdentityHelperTest.php | Adds basic test coverage for the new getIdentity() method |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: ADmad <142658+ADmad@users.noreply.github.com>
Add test coverage for getIdentity() with no identity present
No description provided.