Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Add $orderby and $order params to filter woocommerce_get_catalog_ordering_args #22257
Filter woocommerce_get_catalog_ordering_args has only one single argument $args, anyone filter this needs to detect the $orderby and $order value again which is already coded in the method where this filter returns. I hope adding two extra param $orderby and $order will make developer's life easier to hook this filter.
Changes proposed in this Pull Request:
Method get_catalog_ordering_args in class-wc-query.php , the two variables $orderby and $order already calculated and in the method return filter hook "woocommerce_get_catalog_ordering_args" only have one params $args which I think is not enough or should have more two params $orderby and $order
How to test the changes in this Pull Request: