Overtrue\Socialite\Providers\WeChatProvider::mapUserToObject PHP Method

mapUserToObject() protected method

{@inheritdoc}.
protected mapUserToObject ( array $user )
$user array
    protected function mapUserToObject(array $user)
    {
        return new User(['id' => $this->arrayItem($user, 'openid'), 'name' => $this->arrayItem($user, 'nickname'), 'nickname' => $this->arrayItem($user, 'nickname'), 'avatar' => $this->arrayItem($user, 'headimgurl'), 'email' => null]);
    }