Moralis.User.become

Hey!

Iā€™m looking for detail on how to use this feature. What session token and from where? Do I need to hit the database?

Thanks,

Pat

Moralis.User.become("session-token-here").then(function (user) {
  // The current user is now set to user.
}, function (error) {
  // The token could not be validated.
});

You can get this sessionToken details from Moralis.User.current(); . And u can also get this sessionToken from _Session class in the database.
image

2 Likes