Fix clientId persistence