TutorialEdge

What is this.userSession?

In congito/cognito.js you have the following code:

export default class CognitoAuth {
// The constructor for this class will initialize our userSession
// as null
constructor () {
this.userSession = null
}

userSession is never referenced or touched again anywhere in the code. What does it do or why is it there? I cannot find any references to it in Vue.js, Vue Router or Vue, nor do I find a way it would be used by the Cognito JS SDK. What am I missing? :slight_smile:

Hi MajorTom,

Good catch, I’ll have to have a look and possibly remove this. These tutorials need an update in the coming months to ensure they are on the latest versions so I’ll have a look at ensuring this gets fixed as well!

Thanks for pointing this out!