fix auth loop on index