woocommerce_valid_order_statuses_for_order_again, array( OrderStatus::COMPLETED

woocommerce_valid_order_statuses_for_order_again, array( OrderStatus::COMPLETED

Appears in:
Hook Type: filter

See hook in core

Displaying hooks found in version: woocommerce.11.0.0

apply_filters('woocommerce_valid_order_statuses_for_order_again, array( OrderStatus::COMPLETED') is found 2 times:

  • /includes/class-wc-cart-session.php line 570
    		 * @since 3.6.0
    		 *
    		 * @param array $valid_statuses Array of valid order statuses.
    		 */
    		$valid_statuses = apply_filters( 'woocommerce_valid_order_statuses_for_order_again', array( OrderStatus::COMPLETED ) );
    		if ( ! $order->get_id() || ! $order->has_status( $valid_statuses ) || ! current_user_can( 'order_again', $order->get_id() ) ) {
    			return;
    		}
    
    		if ( apply_filters( 'woocommerce_empty_cart_when_order_again', true ) ) {
    			$cart = array();
    
  • /includes/wc-template-functions.php line 3299
    		 * @since 3.5.0
    		 *
    		 * @param array $statuses_for_reordering Array of valid order statuses for reordering.
    		 */
    		$statuses_for_reordering = apply_filters( 'woocommerce_valid_order_statuses_for_order_again', array( OrderStatus::COMPLETED ) );
    		if ( ! $order || ! $order->has_status( $statuses_for_reordering ) || ! is_user_logged_in() || is_order_received_page() ) {
    			return;
    		}
    
    		wc_get_template(
    			'order/order-again.php',