diff --git a/includes/wc-cart-functions.php b/includes/wc-cart-functions.php index 9aa90a0ad44..ca15a14dfcf 100644 --- a/includes/wc-cart-functions.php +++ b/includes/wc-cart-functions.php @@ -120,7 +120,7 @@ function wc_add_to_cart_message( $products, $show_qty = false, $return = false ) $return_to = apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_raw_referer() ? wp_validate_redirect( wc_get_raw_referer(), false ) : wc_get_page_permalink( 'shop' ) ); $message = sprintf( '%s %s', esc_url( $return_to ), esc_html__( 'Continue shopping', 'woocommerce' ), esc_html( $added_text ) ); } else { - $message = sprintf( '%s %s', esc_url( wc_get_page_permalink( 'cart' ) ), esc_html__( 'View cart', 'woocommerce' ), esc_html( $added_text ) ); + $message = sprintf( '%s %s', esc_url( wc_get_cart_url() ), esc_html__( 'View cart', 'woocommerce' ), esc_html( $added_text ) ); } if ( has_filter( 'wc_add_to_cart_message' ) ) {