| @@ 712-718 (lines=7) @@ | ||
| 709 | ); |
|
| 710 | } |
|
| 711 | ||
| 712 | if ( WC()->cart->needs_shipping() ) { |
|
| 713 | $items[] = array( |
|
| 714 | 'type' => 'final', |
|
| 715 | 'label' => __( 'Shipping', 'woocommerce-gateway-stripe' ), |
|
| 716 | 'amount' => $shipping, |
|
| 717 | ); |
|
| 718 | } |
|
| 719 | ||
| 720 | if ( WC()->cart->has_discount() ) { |
|
| 721 | $items[] = array( |
|
| @@ 720-726 (lines=7) @@ | ||
| 717 | ); |
|
| 718 | } |
|
| 719 | ||
| 720 | if ( WC()->cart->has_discount() ) { |
|
| 721 | $items[] = array( |
|
| 722 | 'type' => 'final', |
|
| 723 | 'label' => __( 'Discount', 'woocommerce-gateway-stripe' ), |
|
| 724 | 'amount' => '-' . $discounts, |
|
| 725 | ); |
|
| 726 | } |
|
| 727 | ||
| 728 | return $items; |
|
| 729 | } |
|