Update with prune function.