SAML2 SSO landing page without redirect

We have an index.html page with the following logic: <head> <script type="text/javascript"> function RedirectToLogin(){ if ( $(".mx-login").length) { window.location.replace("/SSO/") } }</script></head><body class="" dir="ltr" onLoad="setTimeout('RedirectToLogin()', 1500)"> This should cause that the user is redirect to the SSO login, when he is not logged in yet. We use index.html as the SSO Landing Page too. However, in some cases (iOS Safari), the user keeps on seeing the Mendix login page, even when the user is logged in via SSO. Is there a better way to reach the desired behavior? P.S. The reason not to use a second index page (e.g. index-default.html) is that we want the user to bookmark the index.html page.
1 answers

You can better check for a valid session with mendix api than relying on jquery in the the index page. I am sure that thing is already available.