Adapt to new validation api