small fix to upgrade script