Move the session recreate call after all session variables have been registered