Worklight - How to check if a client is already logged in, then pass the login screen

淺唱寂寞╮ 提交于 2019-12-01 12:30:54

This is happening because you're trying to set active user but it is already set. A possible solution might be to call WL.Server.setActiveUser("KlapprAuthRealm", null) before setting active user with actual user identity.

If you want to check on the client side for before submission:

WL.Client.isUserAuthenticated("KlapprAuthRealm")

May want to read the docs on the WL.Client.createChallengeHandler to handle the session and login flow

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!