Skip to content

fix: Bug in fetchIdentities when using first() #1283

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

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

b1tc0re
Copy link

@b1tc0re b1tc0re commented Aug 7, 2025

Description
This PR fixes a critical bug when using withIdentities()->first() and improves test reliability.

Fixed identity loading bug:

  • Added missing ID population for first() method in fetchIdentities
  • Resolved "undefined array key id" error when calling withIdentities()->first()
  • Now correctly handles identity relationships for single results

Checklist:

  • Securely signed commits
  • Component(s) with PHPDoc blocks, only if necessary or adds value
  • Unit testing, with >80% coverage
  • User guide updated
  • Conforms to style guide

@b1tc0re b1tc0re changed the title fix bug in fetchIdentities when using first() fix: Bug in fetchIdentities when using first() Aug 7, 2025
@michalsn
Copy link
Member

michalsn commented Aug 7, 2025

Thanks! However, there's no bug per se - methods like withIdentities(), withGroups(), and withPermissions() are intended to be used with the find* methods.

That said, we're always open to improvements. If you're interested, feel free to update all the relevant methods and documentation accordingly.

@datamweb datamweb added GPG-Signing needed Pull requests that need GPG-Signing enhancement New feature or request labels Aug 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request GPG-Signing needed Pull requests that need GPG-Signing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants