Remove add to cart from referer

Fixes #13618
This commit is contained in:
Mike Jolley 2017-03-16 11:18:15 +00:00
parent 7bd996f45e
commit 5440a45587
1 changed files with 1 additions and 1 deletions

View File

@ -538,7 +538,7 @@ class WC_Form_Handler {
exit;
} elseif ( $cart_updated ) {
wc_add_notice( __( 'Cart updated.', 'woocommerce' ) );
$referer = remove_query_arg( 'remove_coupon', ( wp_get_referer() ? wp_get_referer() : wc_get_cart_url() ) );
$referer = remove_query_arg( array( 'remove_coupon', 'add-to-cart' ), ( wp_get_referer() ? wp_get_referer() : wc_get_cart_url() ) );
wp_safe_redirect( $referer );
exit;
}