philsturgeon / codeigniter-oauth2

NO LONGER ACTIVELY MAINTAINED. USE https://github.com/thephpleague/oauth2-client INSTEAD
http://getsparks.org/packages/oauth2/versions/HEAD/show
351 stars 178 forks source link

Suggestion: Making "WindowsLive" get user email, first_name, last_name #64

Open harpreetsb opened 9 years ago

harpreetsb commented 9 years ago

here is my code suggestion that works with windowslive Outh to provide user email and name FILE - libraries/Provider/Windowslive.php Code

/* at line 49 the return array */
return array(
            'uid'       => $user->id,
            'name'      => $user->name,
            'nickname'  => url_title($user->name, '_', true),
            'first_name' => $user->first_name,
            'last_name' => $user->last_name,
            'email' => $user->emails,
//          'location'  => $user[''], # scope wl.postal_addresses is required
                                          # but won't be implemented by default
            'locale'    => $user->locale,
            'urls'      => array('Windows Live' => $user->link),
        );