parent
6c7aa18199
commit
83a64c048d
|
@ -370,11 +370,14 @@ class WC_Query {
|
||||||
* @param mixed $q
|
* @param mixed $q
|
||||||
*/
|
*/
|
||||||
public function product_query( $q ) {
|
public function product_query( $q ) {
|
||||||
$ordering = $this->get_catalog_ordering_args();
|
if ( ! is_feed() ) {
|
||||||
$q->set( 'orderby', $ordering['orderby'] );
|
$ordering = $this->get_catalog_ordering_args();
|
||||||
$q->set( 'order', $ordering['order'] );
|
$q->set( 'orderby', $ordering['orderby'] );
|
||||||
if ( isset( $ordering['meta_key'] ) ) {
|
$q->set( 'order', $ordering['order'] );
|
||||||
$q->set( 'meta_key', $ordering['meta_key'] );
|
|
||||||
|
if ( isset( $ordering['meta_key'] ) ) {
|
||||||
|
$q->set( 'meta_key', $ordering['meta_key'] );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Query vars that affect posts shown
|
// Query vars that affect posts shown
|
||||||
|
|
Loading…
Reference in New Issue