Recursive patch method.