Integrated upgrade script, removed legacy update code