-
-
Notifications
You must be signed in to change notification settings - Fork 269
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
Multiple identity property for login authentication #258
Comments
I'm thinking |
As @superdweebie said, this is currently unsupported |
I found public function loginAction()
{
$login = $request->getPost('login');
$authenticationService = $this->serviceLocator->get('Zend\Authentication\AuthenticationService');
$adapter = $authenticationService->getAdapter();
if (strpos($login, '@' !== false)) {
// use email identity property
$adapter->getOptions()->setIdentityProperty('email');
} else {
// use username identity property
$adapter->getOptions()->setIdentityProperty('useranme');
}
// Do something...
} @Ocramius, Is this right ? |
@atans that may be a valid workaround, yes. Closing, since I think the feature doesn't need an implementation in the module itself. |
Some commands were not returning the correct exit codes.
Any way to do it?
Thanks !
The text was updated successfully, but these errors were encountered: