Merge pull request #6320 from ryanstockau/master

Fix infinite redirect loop on cart page
This commit is contained in:
Mike Jolley 2014-09-19 10:57:25 +01:00
commit 1fb8582acf
1 changed files with 1 additions and 1 deletions

View File

@ -383,7 +383,7 @@ class WC_Form_Handler {
wc_add_notice( __( 'Cart updated.', 'woocommerce' ) );
$referer = wp_get_referer() ? remove_query_arg( 'add-to-cart', wp_get_referer() ) : WC()->cart->get_cart_url();
$referer = wp_get_referer() ? remove_query_arg( array( 'add-to-cart', 'remove_item' ), wp_get_referer() ) : WC()->cart->get_cart_url();
wp_safe_redirect( $referer );
exit;