Plugin Directory

Changeset 3468700


Ignore:
Timestamp:
02/24/2026 02:20:35 PM (4 weeks ago)
Author:
stitchexpress
Message:

1.3.7

Location:
stitch-express
Files:
6 edited
1 copied

Legend:

Unmodified
Added
Removed
  • stitch-express/tags/1.3.7/includes/stitch-express-client.php

    r3467693 r3468700  
    3838
    3939class Stitch_Express_Client {
    40     private const PLUGIN_VERSION = '1.3.6';
     40    private const PLUGIN_VERSION = '1.3.7';
    4141    private string $baseUrl = 'https://express.stitch.money';
    4242    private string $client_id;
  • stitch-express/tags/1.3.7/readme.txt

    r3467693 r3468700  
    33Tags: woocommerce, card, payments, south africa, apple pay, google pay, stitch, express, stitch express
    44Tested up to: 6.7
    5 Stable tag: 1.3.6
     5Stable tag: 1.3.7
    66License: GPLv3
    77License URI: https://www.gnu.org/licenses/gpl-3.0.html
     
    8383
    8484== Changelog ==
     85= 1.3.7 =
     86* Minor fixes and improvements
     87
    8588= 1.3.6 =
    8689* Add BNPL Product Widget with customizable settings
     
    172175
    173176== Upgrade Notice ==
     177= 1.3.7 =
     178* Minor fixes and improvements
     179
    174180= 1.3.6 =
    175181* New BNPL Product Widget feature - Show "Buy Now Pay Later" messaging on product pages
  • stitch-express/tags/1.3.7/stitch-express.php

    r3467693 r3468700  
    99 * Description:          Use Stitch Express to easily and securely accept Card payment on your WooCommerce store.
    1010 * Plugin URI:           https://wordpress.org/plugins/stitchexpress/
    11  * Version:              1.3.6
     11 * Version:              1.3.7
    1212 * Requires at least:    6.5
    1313 * Requires PHP:         8.0
     
    136136    }
    137137
    138     // Process payment if order is awaiting payment OR override flag is set
    139     // Check both 'awaiting-payment' (plugin custom status) and 'pending' (WooCommerce default)
    140     $is_awaiting_payment = in_array($order->get_status(), ['awaiting-payment', 'pending'], true);
    141 
    142     if ($is_awaiting_payment || $override) {
     138    $can_complete_payment = in_array($order->get_status(), ['awaiting-payment', 'pending', 'cancelled', 'failed'], true);
     139
     140    if ($can_complete_payment || $override) {
     141        if (in_array($order->get_status(), ['cancelled', 'failed'], true)) {
     142            $order->add_order_note(
     143                sprintf(
     144                    'Stitch Express: Payment confirmed (ID: %s) while order was "%s". Overriding status and completing payment.',
     145                    $payment_id,
     146                    $order->get_status()
     147                )
     148            );
     149        }
     150
    143151        $logger->info(
    144152            "Marking order {$order_id} with status '{$order->get_status()}' as complete. Stitch Payment ID: {$payment_id}",
     
    152160    }
    153161
    154     // Skip payment completion to prevent duplicate notifications
    155162    $logger->info("Order {$order_id} status is '{$order->get_status()}', skipping payment completion", ['source' => 'stitch-express']);
    156163
     
    250257    }
    251258
    252     // Process payment if order is awaiting payment
    253     $is_awaiting_payment = in_array($order->get_status(), ['awaiting-payment', 'pending'], true);
    254 
    255     if ($is_awaiting_payment) {
     259    $can_complete_payment = in_array($order->get_status(), ['awaiting-payment', 'pending', 'cancelled', 'failed'], true);
     260
     261    if ($can_complete_payment) {
     262        if (in_array($order->get_status(), ['cancelled', 'failed'], true)) {
     263            $order->add_order_note(
     264                sprintf(
     265                    'Stitch Express: Payment confirmed (ID: %s) while order was "%s". Overriding status and completing payment.',
     266                    $payment_id,
     267                    $order->get_status()
     268                )
     269            );
     270        }
     271
    256272        $logger->info(
    257273            "Webhook: Marking order {$order_id} with status '{$order->get_status()}' as complete. Stitch Payment ID: {$payment_id}",
  • stitch-express/trunk/includes/stitch-express-client.php

    r3467693 r3468700  
    3838
    3939class Stitch_Express_Client {
    40     private const PLUGIN_VERSION = '1.3.6';
     40    private const PLUGIN_VERSION = '1.3.7';
    4141    private string $baseUrl = 'https://express.stitch.money';
    4242    private string $client_id;
  • stitch-express/trunk/readme.txt

    r3467693 r3468700  
    33Tags: woocommerce, card, payments, south africa, apple pay, google pay, stitch, express, stitch express
    44Tested up to: 6.7
    5 Stable tag: 1.3.6
     5Stable tag: 1.3.7
    66License: GPLv3
    77License URI: https://www.gnu.org/licenses/gpl-3.0.html
     
    8383
    8484== Changelog ==
     85= 1.3.7 =
     86* Minor fixes and improvements
     87
    8588= 1.3.6 =
    8689* Add BNPL Product Widget with customizable settings
     
    172175
    173176== Upgrade Notice ==
     177= 1.3.7 =
     178* Minor fixes and improvements
     179
    174180= 1.3.6 =
    175181* New BNPL Product Widget feature - Show "Buy Now Pay Later" messaging on product pages
  • stitch-express/trunk/stitch-express.php

    r3467693 r3468700  
    99 * Description:          Use Stitch Express to easily and securely accept Card payment on your WooCommerce store.
    1010 * Plugin URI:           https://wordpress.org/plugins/stitchexpress/
    11  * Version:              1.3.6
     11 * Version:              1.3.7
    1212 * Requires at least:    6.5
    1313 * Requires PHP:         8.0
     
    136136    }
    137137
    138     // Process payment if order is awaiting payment OR override flag is set
    139     // Check both 'awaiting-payment' (plugin custom status) and 'pending' (WooCommerce default)
    140     $is_awaiting_payment = in_array($order->get_status(), ['awaiting-payment', 'pending'], true);
    141 
    142     if ($is_awaiting_payment || $override) {
     138    $can_complete_payment = in_array($order->get_status(), ['awaiting-payment', 'pending', 'cancelled', 'failed'], true);
     139
     140    if ($can_complete_payment || $override) {
     141        if (in_array($order->get_status(), ['cancelled', 'failed'], true)) {
     142            $order->add_order_note(
     143                sprintf(
     144                    'Stitch Express: Payment confirmed (ID: %s) while order was "%s". Overriding status and completing payment.',
     145                    $payment_id,
     146                    $order->get_status()
     147                )
     148            );
     149        }
     150
    143151        $logger->info(
    144152            "Marking order {$order_id} with status '{$order->get_status()}' as complete. Stitch Payment ID: {$payment_id}",
     
    152160    }
    153161
    154     // Skip payment completion to prevent duplicate notifications
    155162    $logger->info("Order {$order_id} status is '{$order->get_status()}', skipping payment completion", ['source' => 'stitch-express']);
    156163
     
    250257    }
    251258
    252     // Process payment if order is awaiting payment
    253     $is_awaiting_payment = in_array($order->get_status(), ['awaiting-payment', 'pending'], true);
    254 
    255     if ($is_awaiting_payment) {
     259    $can_complete_payment = in_array($order->get_status(), ['awaiting-payment', 'pending', 'cancelled', 'failed'], true);
     260
     261    if ($can_complete_payment) {
     262        if (in_array($order->get_status(), ['cancelled', 'failed'], true)) {
     263            $order->add_order_note(
     264                sprintf(
     265                    'Stitch Express: Payment confirmed (ID: %s) while order was "%s". Overriding status and completing payment.',
     266                    $payment_id,
     267                    $order->get_status()
     268                )
     269            );
     270        }
     271
    256272        $logger->info(
    257273            "Webhook: Marking order {$order_id} with status '{$order->get_status()}' as complete. Stitch Payment ID: {$payment_id}",
Note: See TracChangeset for help on using the changeset viewer.