fixed upgrade
small fixes