contact-list/public/components/auth/auth.service.js
// This method is called from app.run.js
This method is called from app.run.js
This method is called from app . run . js
function registerAuthenticationListener() {
                    lock.on('authenticated', function (authResult) {
                        localStorage.setItem('id_token', authResult.idToken);
                        authManager.authenticate();
                        lock.getProfile(authResult.idToken, function (error, profile) {
                            if (error) {
                                return console.log(error);
                            }
                            localStorage.setItem('profile', JSON.stringify(profile));
                            deferredProfile.resolve(profile);
                        });
                    });
                }
function registerAuthenticationListener ( ) { lock . on ( 'authenticated' , function ( authResult ) { localStorage . setItem ( 'id_token' , authResult . idToken ) ; authManager . authenticate ( ) ; lock . getProfile ( authResult . idToken , function ( error , profile ) { if ( error ) { return console . log ( error ) ; } localStorage . setItem ( 'profile' , JSON . stringify ( profile ) ) ; deferredProfile . resolve ( profile ) ; } ) ; } ) ; }
This method is called from app.run.js
This method is called from app . run . js