Upgrade and code