Added update function to main class