updated the update() method in the map class