Merge pull request #21328 from woocommerce/fix/21321

wc-checkout js params use is_checkout
This commit is contained in:
Claudiu Lodromanean 2018-09-12 07:53:32 -07:00 committed by GitHub
commit c3170b423b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -509,7 +509,7 @@ class WC_Frontend_Scripts {
'remove_coupon_nonce' => wp_create_nonce( 'remove-coupon' ),
'option_guest_checkout' => get_option( 'woocommerce_enable_guest_checkout' ),
'checkout_url' => WC_AJAX::get_endpoint( 'checkout' ),
'is_checkout' => is_page( wc_get_page_id( 'checkout' ) ) && empty( $wp->query_vars['order-pay'] ) && ! isset( $wp->query_vars['order-received'] ) ? 1 : 0,
'is_checkout' => is_checkout() && empty( $wp->query_vars['order-pay'] ) && ! isset( $wp->query_vars['order-received'] ) ? 1 : 0,
'debug_mode' => defined( 'WP_DEBUG' ) && WP_DEBUG,
'i18n_checkout_error' => esc_attr__( 'Error processing checkout. Please try again.', 'woocommerce' ),
);