Fix woocommerce_reset_loop Closes #4443
This commit is contained in:
parent
b9a78b5894
commit
211658a8f4
|
@ -191,6 +191,7 @@ class WC_Shortcodes {
|
|||
|
||||
<?php endif;
|
||||
|
||||
woocommerce_reset_loop();
|
||||
wp_reset_postdata();
|
||||
|
||||
return '<div class="woocommerce columns-' . $columns . '">' . ob_get_clean() . '</div>';
|
||||
|
|
|
@ -547,7 +547,7 @@ if ( ! function_exists( 'woocommerce_reset_loop' ) ) {
|
|||
function woocommerce_reset_loop() {
|
||||
global $woocommerce_loop;
|
||||
// Reset loop/columns globals when starting a new loop
|
||||
$woocommerce_loop['loop'] = $woocommerce_loop['column'] = '';
|
||||
$woocommerce_loop['loop'] = $woocommerce_loop['columns'] = '';
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue