-
-
Notifications
You must be signed in to change notification settings - Fork 245
Description
Hello!
I have a question/suggestion/problem - depends on your answer.
BaseClient.php has normalizeUserAttributeMap attribute with description where saying that we can pass an array for normalize attribute. Can you give more detailed information for what it can be used?
In my understanding, for example:
'normalizeUserAttributeMap' => [
'email' => ['email', 'name'],
]
If email found - using it, if not - trying to use name attribute.
In real - if one of attribute from array not found it's $isFound = false; here https://github.com/yiisoft/yii2-authclient/blob/master/src/BaseClient.php#L359 and in result I don't have any data in attribute.
Please, if my understanding is not right - explain what for array can be used. And second - can we make opportunities for normalize attribute in that way how I understanding now?
Thanks for your time in advance.
P.S. I know that I can use function instead of array but I think if else in each client config is not pretty nice.