GopalSharma / moodle-auth_azureb2c

The Azure AD B2C Connect plugin provides registering of a new user and single-sign-on functionality using configurable identity providers, scope and custom policies of Azure B2C.
GNU General Public License v3.0
2 stars 7 forks source link

Issue #8 - Column 'token' cannot be null #9

Closed emyb2 closed 10 months ago

emyb2 commented 3 years ago

This addresses Issue #8 while preserving the existing code as I am not sure if some B2C connection responses have the key access_token.

Address token cannot be null. There is also an undefined index access_token. Added conditional checking incase access_token is used. Add fallback for id_token to be in place of the token record

jjcantillon commented 2 years ago

This fixed #8 for me. Thanks @emyb2

emyb commented 2 years ago

@jjcantillon - I ended up adding the client id as a parameter in the scope and it worked

Screen Shot 2022-07-08 at 1 59 07 PM

emyb commented 2 years ago

@GopalSharma I believe this one can be closed now