Better approach to #14955

We can just detect if the function is there, so that we on;y need
to add it if the kwargs do need to be massaged.