datamweb / shield-oauth

OAuth for CodeIgniter Shield
https://www.shield-oauth.codeigniter4.ir/
MIT License
61 stars 16 forks source link

Bug: namespace Datamweb\ShieldOAuth\Libraries\GoogleOAuth class line 100 uses an incorrect property for the user's first name. #177

Open AaronMk44 opened 3 weeks ago

AaronMk44 commented 3 weeks ago

PHP Version

8.1

CodeIgniter4 Version

4.5.5

Shield Version

1.1

Shield OAuth Version?

dev-develop

Which operating systems have you tested for this bug?

Windows

Which server did you use?

apache

Database

MariaDB

Did you add customize OAuth?

Google

What happened?

The first name column in the database table had the user's first and last name combined. After checking the data coming back from the Google OAuth system. It returns the following field: name, given_name, family_name, .... It seems the library (this) uses the 'name' field instead of 'given_name.'

Steps to Reproduce

Integrate Google Sign in into a blank CodeIgniter 4 project using this library. Follow the docs

Expected Output

The first name must only have the first name and the last name must only have the last name. This is in connection with the users table.

Anything else?

Nothing

datamweb commented 3 weeks ago

Maybe related to #111