Remove unnecessary upgrade code