fix the upgrade