Closed joaopatrocinio closed 1 year ago
The result you're returning from your finder needs to have username + password accessible based on the fields
configuration. See the logic used by PasswordIdentifier
:
If you can't / don't want to make that work, then you'll need to build your own identifier implementation that works with your schema.
Thank you, this helped me understand better how the identification process works. I was able to make the login work by creating a virtual field in the User entity. In the future I will implement an identifier which can accept array-like fields, so that I can identify with a joined table.
I'm trying to implement this plugin where the database has the username decoupled from the password table, like so:
users: id username is_active
passwords: id password is_active fk_user_id
This is how the middleware is set:
And this is my finder:
And I'm getting this result when I login: