Update method.