fix session redirect