Regulating urban upgrading in developing countries