fixed hierarchy upside-down bug