Implemented 'update' method