Add upgrade function to upgrader