I set up my app's authentication system based on the Symfony2 security documentation.
Each one of my users has an active
flag. I don't want users whose active
= false to be able to log in.
I don't really understand where the logic is that says whether or not a user is allowed to log in, so I'm somewhat at a loss as to how to accomplish this. Can someone please steer me in the right direction?
Make your User
class implement AdvancedUserInterface
— it has the isEnabled()
method specifically for that purpose.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With