Skip to content

resetAuth

Sahri Riza Umami edited this page Mar 14, 2017 · 6 revisions

Logs out user.

resetAuth()
resetAuth(force)
Option Description
force If true, just delete all local data. Session will remain in list of active sessions.

If force == false, begins to perform soft log out, returns authStateLoggingOut after completion.
If force == true then succeeds almost immediately without cleaning anything at the server, but returns error with code 401 and description "Unauthorized".

Example

  • Soft log out from currently logged in user.

    resetAuth(0)
  • Log out from currently logged in user and delete all of its local data.

    resetAuth(1)

Test script
Frequently Asked Questions
The Functions

Clone this wiki locally