Added Ruibin's modified fix_umbrella code