Functionality for updating the objects, needs proper testing