move pageIsLoaded() from login() into correctLogin()