Fix the path passed to the filter function.