Plugin Directory

Changeset 3321269


Ignore:
Timestamp:
07/02/2025 02:05:46 PM (9 months ago)
Author:
Biont
Message:

update develop branch with Version 3.4.0

Location:
payoneer-checkout/trunk
Files:
37 added
96 edited

Legend:

Unmodified
Added
Removed
  • payoneer-checkout/trunk/TODOS.md

    r3305047 r3321269  
    55| [modules.local/analytics/inc/services.php](modules.local/analytics/inc/services.php#L309) | 309 | replace with production value |
    66| [modules.local/checkout/inc/services.php](modules.local/checkout/inc/services.php#L132) | 132 | use min.js when script debug is enabled |
    7 | [modules.local/checkout/inc/services.php](modules.local/checkout/inc/services.php#L272) | 272 | consider adding our own hidden block to checkout for our custom fields, |
    8 | [modules.local/checkout/src/CheckoutModule.php](modules.local/checkout/src/CheckoutModule.php#L474) | 474 | supply a proper css file for this. Rework markup into something more responsive |
    9 | [modules.local/embedded-payment/src/EmbeddedPaymentModule.php](modules.local/embedded-payment/src/EmbeddedPaymentModule.php#L225) | 225 | Remove this check when support for these versions is dropped |
    10 | [modules.local/embedded-payment/src/EmbeddedPaymentModule.php](modules.local/embedded-payment/src/EmbeddedPaymentModule.php#L300) | 300 | Refactor the environment detection to use the current WP options. |
    11 | [modules.local/embedded-payment/src/EmbeddedPaymentModule.php](modules.local/embedded-payment/src/EmbeddedPaymentModule.php#L304) | 304 | Determine whether we can get SRI details (URL + hash) from the LIST response, and drop this service. |
    12 | [modules.local/embedded-payment/src/EmbeddedPaymentModule.php](modules.local/embedded-payment/src/EmbeddedPaymentModule.php#L311) | 311 | Consider returning the full SDK URL instead of only the environment. We could return the final `websdk.assets.umd.url.template` here. |
     7| [modules.local/checkout/inc/services.php](modules.local/checkout/inc/services.php#L285) | 285 | consider adding our own hidden block to checkout for our custom fields, |
     8| [modules.local/checkout/src/CheckoutModule.php](modules.local/checkout/src/CheckoutModule.php#L339) | 339 | supply a proper css file for this. Rework markup into something more responsive |
     9| [modules.local/embedded-payment/src/EmbeddedPaymentModule.php](modules.local/embedded-payment/src/EmbeddedPaymentModule.php#L221) | 221 | Remove this check when support for these versions is dropped |
     10| [modules.local/embedded-payment/src/EmbeddedPaymentModule.php](modules.local/embedded-payment/src/EmbeddedPaymentModule.php#L310) | 310 | Refactor the environment detection to use the current WP options. |
     11| [modules.local/embedded-payment/src/EmbeddedPaymentModule.php](modules.local/embedded-payment/src/EmbeddedPaymentModule.php#L314) | 314 | Determine whether we can get SRI details (URL + hash) from the LIST response, and drop this service. |
     12| [modules.local/embedded-payment/src/EmbeddedPaymentModule.php](modules.local/embedded-payment/src/EmbeddedPaymentModule.php#L321) | 321 | Consider returning the full SDK URL instead of only the environment. We could return the final `websdk.assets.umd.url.template` here. |
    1313| [modules.local/embedded-payment/src/ListLongIdPaymentRequestValidator.php](modules.local/embedded-payment/src/ListLongIdPaymentRequestValidator.php#L56) | 56 | Put this in a const/enum or make it a constructor argument |
    14 | [modules.local/list-session/inc/services.php](modules.local/list-session/inc/services.php#L240) | 240 | consider doing the same with the WC_Session List provider |
    1514| [modules.local/list-session/src/ListSessionModule.php](modules.local/list-session/src/ListSessionModule.php#L62) | 62 | check if we still need this after Fetch command is implemented |
    16 | [modules.local/payment-methods/inc/services.php](modules.local/payment-methods/inc/services.php#L364) | 364 | consider refactoring, these callbacks are almost the same. |
     15| [modules.local/payment-methods/inc/services.php](modules.local/payment-methods/inc/services.php#L311) | 311 | think about moving this to factories |
     16| [modules.local/payment-methods/inc/services.php](modules.local/payment-methods/inc/services.php#L359) | 359 | consider refactoring, these callbacks are almost the same. |
    1717| [modules.local/settings/src/SettingsModule.php](modules.local/settings/src/SettingsModule.php#L758) | 758 | Remove/Refactor this when WC 9.7+ releases the revamped Payment Settings UX |
    1818| [modules.local/wp/inc/factories.php](modules.local/wp/inc/factories.php#L18) | 18 | make our order_pay request be detected as a checkout in the same way as |
    19 | [modules.local/wp/inc/services.php](modules.local/wp/inc/services.php#L345) | 345 | check if this can return false because called too early |
     19| [modules.local/wp/inc/services.php](modules.local/wp/inc/services.php#L288) | 288 | deal with the code duplication. Currently, we have the same logic |
     20| [modules.local/wp/inc/services.php](modules.local/wp/inc/services.php#L349) | 349 | check if this can return false because called too early |
    2021| [modules.local/embedded-payment/src/PaymentFieldsRenderer/WidgetPlaceholderFieldRenderer.php](modules.local/embedded-payment/src/PaymentFieldsRenderer/WidgetPlaceholderFieldRenderer.php#L55) | 55 | Reuse another message here. The actual HPP flow uses a merchant-configurable string |
    21 | [modules.local/list-session/src/ListSession/ListSessionManager.php](modules.local/list-session/src/ListSession/ListSessionManager.php#L45) | 45 | turn this global method into a service so that we can use proper dependencies from our container |
     22| [modules.local/list-session/src/Middleware/UpdatingMiddleware.php](modules.local/list-session/src/Middleware/UpdatingMiddleware.php#L110) | 110 | replace this with a better solution. |
     23| [modules.local/list-session/src/Middleware/UpdatingMiddleware.php](modules.local/list-session/src/Middleware/UpdatingMiddleware.php#L123) | 123 | Log errors during UPDATE |
    2224| [modules.local/payment-methods/src/GatewayIconsRenderer/DynamicIconProvider.php](modules.local/payment-methods/src/GatewayIconsRenderer/DynamicIconProvider.php#L77) | 77 | logging |
    2325| [modules.local/api/tests/php/Integration/Gateway/PaymentTestCase.php](modules.local/api/tests/php/Integration/Gateway/PaymentTestCase.php#L22) | 22 | replace 'inpsyde_payment_gateway.payoneer' with a mocked PaymentProcessor/ChargeCommand |
  • payoneer-checkout/trunk/changelog.txt

    r3305047 r3321269  
    33= [next-version] - yyyy-mm-dd =
    44
    5 = [3.3.2] - 2025-06-02 =
     5= [3.4.0] - 2025-06-30 =
     6* Added
     7    * Automated generation of System Status Reports and Logfiles to assist support processes.
     8
     9* Fixed
     10    * Resolved payment rejection issue caused by an incorrect Security header.
     11    * Fixed compatibility issue with WordPress Multisite.
     12    * Addressed an incompatibility with WooCommerce Multilingual & Multicurrency that caused the Pay for Order page to break.
     13    * Ensured available payment methods in the LIST are correctly updated after changes to the total amount.
     14
     15* Changed
     16    * Adjust value handling to not include customer.number as a required value in SDK
     17    * Removed the ProcessingModel entity for MoR from the SDK.
     18
     19= [3.3.2] - 2025-05-26 =
    620* Fixed:
    721  * Issue allowing checkout form to be submitted with invalid cards fields
     
    923  * PHP 8+ errors caused during API calls after 3.3.0 release
    1024  * PHP 7.4 errors caused during API calls after 3.3.0 release
     25
    1126* Changed:
    1227  * Repeated payment attempts no longer generate new orders. The original order is now reused, with its status set to On hold after checkout and updated to Failed if the payment is declined.
     
    1429= [3.3.1] - 2025-04-02 =
    1530* Added
    16     * SRI integrity hash (security enhancement for PSI/DSS 4.0 compatibility)
     31    * SRI integrity hash (security enhancement for PCI-DSS 4.0 compatibility)
    1732
    1833= [3.3.0] - 2025-03-24 =
  • payoneer-checkout/trunk/inc/extensions.php

    r3260742 r3321269  
    3939                $message = $exception->getMessage();
    4040                return \sprintf('Failed to update LIST session: %1$s.', $message);
    41             }], ['name' => 'payoneer-checkout.create_list_session_failed', 'log_level' => LogLevel::ERROR, 'message' => 'Failed to create LIST session. Exception caught: {exception}'], ['name' => 'payoneer-checkout.list_session_created', 'log_level' => LogLevel::INFO, 'message' => 'LIST session {longId} was successfully created.'], ['name' => 'payoneer-checkout.payment_processing_failure', 'log_level' => LogLevel::WARNING, 'message' => 'Failed to process checkout payment. Exception caught: {errorMessage}'], ['name' => $cardsGatewayId . '_payment_fields_failure', 'log_level' => LogLevel::ERROR, 'message' => 'Failed to render payment fields. Exception caught: {exception}'], ['name' => 'payoneer-checkout.before_create_list', 'log_level' => LogLevel::INFO, 'message' => 'Started creating list session.'], ['name' => 'payoneer-checkout.log_incoming_notification', 'log_level' => LogLevel::INFO, 'message' => 'Incoming webhook with HTTP method {method}.' . \PHP_EOL . 'Query params are {queryParams}.' . \PHP_EOL . 'Body content is {bodyContents}.' . \PHP_EOL . 'Headers are {headers}.'], ['name' => 'payoneer-checkout.webhook_request.order_not_found', 'log_level' => LogLevel::ERROR, 'message' => 'Order not found by transaction ID {transactionId}, longId is {longId}.'], ['name' => 'payoneer-checkout.webhook_request.order_auth_header_is_incorrect', 'log_level' => LogLevel::ERROR, 'message' => 'Order authorization header is incorrect. Order id is {orderId}, longId is {longId}.'], ['name' => 'payoneer-checkout.webhook_request.webhook_already_processed', 'log_level' => LogLevel::WARNING, 'message' => 'Incoming webhook was processed already, skipping. Order id is {orderId}, longId is {longId}.'], ['name' => 'woocommerce_create_order', 'log_level' => LogLevel::INFO, 'message' => 'Started creating order on checkout.'], ['name' => 'woocommerce_checkout_order_created', 'log_level' => LogLevel::INFO, 'message' => 'Order creating finished.'], ['name' => 'payoneer-checkout.before_update_order_metadata', 'log_level' => LogLevel::INFO, 'message' => 'Order meta update started.'], ['name' => 'payoneer-checkout.after_update_order_metadata', 'log_level' => LogLevel::INFO, 'message' => 'Order meta update finished.'], ['name' => 'payoneer-checkout.before_update_list', 'log_level' => LogLevel::INFO, 'message' => 'Started updating list session {longId}'], ['name' => 'payoneer-checkout.list_session_updated', 'log_level' => LogLevel::INFO, 'message' => 'List session {longId} was successfully updated'], ['name' => 'payoneer_checkout.invalid_country_after_final_update', 'log_level' => LogLevel::ERROR, 'message' => 'Final update without List.country set or List.country is different from customers billing country'], ['name' => 'payoneer-checkout.missing-headers-for-validation', 'log_level' => LogLevel::ERROR, 'message' => static function (array $args) {
     41            }], ['name' => 'payoneer-checkout.create_list_session_failed', 'log_level' => LogLevel::ERROR, 'message' => 'Failed to create LIST session. Exception caught: {exception}'], ['name' => 'payoneer-checkout.list_session_created', 'log_level' => LogLevel::INFO, 'message' => 'LIST session {longId} was successfully created.'], ['name' => 'payoneer-checkout.payment_processing_failure', 'log_level' => LogLevel::WARNING, 'message' => 'Failed to process checkout payment. Exception caught: {errorMessage}'], ['name' => $cardsGatewayId . '_payment_fields_failure', 'log_level' => LogLevel::ERROR, 'message' => 'Failed to render payment fields. Exception caught: {exception}'], ['name' => 'payoneer-checkout.before_create_list', 'log_level' => LogLevel::INFO, 'message' => 'Started creating list session.'], ['name' => 'payoneer-checkout.log_incoming_notification', 'log_level' => LogLevel::INFO, 'message' => 'Incoming webhook with HTTP method {method}.' . \PHP_EOL . 'Query params are {queryParams}.' . \PHP_EOL . 'Body content is {bodyContents}.' . \PHP_EOL . 'Headers are {headers}.'], ['name' => 'payoneer-checkout.webhook_request.order_not_found', 'log_level' => LogLevel::ERROR, 'message' => 'Order not found by transaction ID {transactionId}, longId is {longId}.'], ['name' => 'payoneer-checkout.webhook_request.order_auth_header_is_incorrect', 'log_level' => LogLevel::ERROR, 'message' => 'Order authorization header is incorrect. Order id is {orderId}, longId is {longId}.'], ['name' => 'payoneer-checkout.webhook_request.webhook_already_processed', 'log_level' => LogLevel::WARNING, 'message' => 'Incoming webhook was processed already, skipping. Order id is {orderId}, longId is {longId}.'], ['name' => 'payoneer-checkout.webhook_request.multiple_orders_found_for_transaction_id', 'log_level' => LogLevel::WARNING, 'message' => 'Found more than one order for transactionId in the incoming webhook'], ['name' => 'woocommerce_create_order', 'log_level' => LogLevel::INFO, 'message' => 'Started creating order on checkout.'], ['name' => 'woocommerce_checkout_order_created', 'log_level' => LogLevel::INFO, 'message' => 'Order creating finished.'], ['name' => 'payoneer-checkout.before_update_order_metadata', 'log_level' => LogLevel::INFO, 'message' => 'Order meta update started.'], ['name' => 'payoneer-checkout.after_update_order_metadata', 'log_level' => LogLevel::INFO, 'message' => 'Order meta update finished.'], ['name' => 'payoneer-checkout.before_update_list', 'log_level' => LogLevel::INFO, 'message' => 'Started updating list session {longId}'], ['name' => 'payoneer-checkout.list_session_updated', 'log_level' => LogLevel::INFO, 'message' => 'List session {longId} was successfully updated'], ['name' => 'payoneer_checkout.invalid_country_after_final_update', 'log_level' => LogLevel::ERROR, 'message' => 'Final update without List.country set or List.country is different from customers billing country'], ['name' => 'payoneer-checkout.missing-headers-for-validation', 'log_level' => LogLevel::ERROR, 'message' => static function (array $args) {
    4242                /**
    4343                 * @var array $headers
     
    4545                $headers = $args['headers'];
    4646                return \sprintf('Missing required HTTP header for checkout validation. Headers received: %1$s.', (string) \wc_print_r(\array_keys($headers), \true));
    47             }]];
     47            }], ['name' => 'payoneer-checkout.status-report.email-sent', 'log_level' => LogLevel::INFO, 'message' => 'System report - Successfully sent the email.'], ['name' => 'payoneer-checkout.status-report.email-failed', 'log_level' => LogLevel::ERROR, 'message' => 'System report - Failed to send the email.'], ['name' => 'payoneer-checkout.status-report.cannot-add-attachments', 'log_level' => LogLevel::ERROR, 'message' => 'System report - The PHPMailer instance cannot add string attachments.'], ['name' => 'payoneer-checkout.status-report.attachment-failed', 'log_level' => LogLevel::ERROR, 'message' => 'System report - Failed to attach "{filename}" to the email.']];
    4848            return \array_merge($previous, $logEventsToAdd, $gatewaysProcessingSuccess);
    4949        },
  • payoneer-checkout/trunk/inc/services.php

    r3206335 r3321269  
    286286        # core.refund
    287287        # =================================================================
    288         'core.refund.refund_finder' => new Alias('webhooks.refund_finder'),
     288        'core.refund.refund_finder' => new Alias('wp.refund_finder'),
    289289        # core.data
    290290        # =================================================================
     
    614614        'inpsyde_payment_gateway.address_factory' => new Alias('core.address_factory'),
    615615        'inpsyde_payment_gateway.name_factory' => new Alias('core.name_factory'),
    616         'inpsyde_payment_gateway.order_finder' => new Alias('webhooks.order_finder'),
     616        'inpsyde_payment_gateway.order_finder' => new Alias('wp.order_finder'),
    617617        'inpsyde_payment_gateway.product_factory' => new Alias('core.product_factory'),
    618618        'inpsyde_payment_gateway.list_hash_container_id' => new Alias('core.list_hash_container_id'),
  • payoneer-checkout/trunk/languages/en_GB.pot

    r3305047 r3321269  
    1818#: payoneer-checkout.php
    1919#: modules.local/settings/inc/services.php:568
    20 #: modules.local/status-report/src/StatusReportModule.php:59
     20#: modules.local/status-report/src/StatusReportModule.php:68
    2121#: modules/inpsyde/payoneer-settings/inc/services.php:568
    22 #: modules/inpsyde/payoneer-status-report/src/StatusReportModule.php:59
     22#: modules/inpsyde/payoneer-status-report/src/StatusReportModule.php:68
    2323msgid "Payoneer Checkout"
    2424msgstr ""
     
    4545
    4646#. translators: Used when encountering the ABORT interaction code
    47 #: inc/extensions.php:210
     47#: inc/extensions.php:240
    4848msgid "The payment has been aborted"
    4949msgstr ""
    5050
    5151#. translators: Used when encountering the TRY_OTHER_NETWORK interaction code
    52 #: inc/extensions.php:212
     52#: inc/extensions.php:242
    5353msgid "Please try another network"
    5454msgstr ""
    5555
    5656#. translators: Used when encountering the TRY_OTHER_ACCOUNT interaction code
    57 #: inc/extensions.php:214
     57#: inc/extensions.php:244
    5858msgid "Please try another account"
    5959msgstr ""
    6060
    6161#. translators: Used when encountering the RETRY interaction code
    62 #: inc/extensions.php:216
     62#: inc/extensions.php:246
    6363msgid "Please attempt the payment again"
    6464msgstr ""
    6565
    6666#. translators: Used when encountering the VERIFY interaction code
    67 #: inc/extensions.php:218
     67#: inc/extensions.php:248
    6868msgid "Payment requires verification"
    6969msgstr ""
     
    118118
    119119#. translators: When detecting an ABORT interaction code upon redirecting to the cancelUrl
    120 #: modules.local/checkout/src/CheckoutModule.php:380
    121 #: modules/inpsyde/payoneer-payment-gateway-checkout/src/CheckoutModule.php:380
     120#: modules.local/checkout/src/CheckoutModule.php:253
     121#: modules/inpsyde/payoneer-payment-gateway-checkout/src/CheckoutModule.php:253
    122122msgid "Payment has been aborted"
    123123msgstr ""
    124124
    125 #: modules.local/checkout/src/CheckoutModule.php:399
    126 #: modules/inpsyde/payoneer-payment-gateway-checkout/src/CheckoutModule.php:399
     125#: modules.local/checkout/src/CheckoutModule.php:268
     126#: modules/inpsyde/payoneer-payment-gateway-checkout/src/CheckoutModule.php:268
    127127msgid "Payment failed. Please try again"
    128128msgstr ""
    129129
    130130#. translators: Notice when redirecting to cancelUrl (after failed 3DS challenge or customer abort)
    131 #: modules.local/checkout/src/CheckoutModule.php:402
    132 #: modules/inpsyde/payoneer-payment-gateway-checkout/src/CheckoutModule.php:402
     131#: modules.local/checkout/src/CheckoutModule.php:271
     132#: modules/inpsyde/payoneer-payment-gateway-checkout/src/CheckoutModule.php:271
    133133msgid "Payment canceled. Please try again or choose another payment method."
    134134msgstr ""
    135135
    136136#. translators: %1$s, %2$s and %3$s are replaced with the opening and closing 'a' tags
    137 #: modules.local/checkout/src/CheckoutModule.php:554
    138 #: modules/inpsyde/payoneer-payment-gateway-checkout/src/CheckoutModule.php:554
     137#: modules.local/checkout/src/CheckoutModule.php:419
     138#: modules/inpsyde/payoneer-payment-gateway-checkout/src/CheckoutModule.php:419
    139139#, php-format
    140140msgid "Enter valid Test credentials and Save settings to receive a payment notification and unlock Live mode checkbox. You can %1$srefresh%2$s the page to check if a payment notification has been already received and Live mode checkbox is unlocked."
     
    142142
    143143#. translators: Transaction ID supplied by WooCommerce plugin
    144 #: modules.local/checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:174
    145 #: modules/inpsyde/payoneer-payment-gateway-checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:174
     144#: modules.local/checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:147
     145#: modules/inpsyde/payoneer-payment-gateway-checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:147
    146146#, php-format
    147147msgid "Initiating payment with transaction ID \"%1$s\""
    148148msgstr ""
    149149
    150 #: modules.local/checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:215
    151 #: modules/inpsyde/payoneer-payment-gateway-checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:215
     150#: modules.local/checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:188
     151#: modules/inpsyde/payoneer-payment-gateway-checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:188
    152152msgid "The payment was not processed. Please try again."
    153153msgstr ""
    154154
    155155#. translators: Used after checking for misconfigured merchant credentials, e.g. when we encounter 401/INVALID_CONFIGURATION
    156 #: modules.local/checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:261
    157 #: modules/inpsyde/payoneer-payment-gateway-checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:261
     156#: modules.local/checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:234
     157#: modules/inpsyde/payoneer-payment-gateway-checkout/src/PaymentProcessor/AbstractPaymentProcessor.php:234
    158158msgid "Failed to initialize payment session. Payoneer Checkout is not configured properly."
    159159msgstr ""
     
    194194
    195195#. translators: An unexpected error during the final List UPDATE before the CHARGE
    196 #: modules.local/embedded-payment/src/PaymentProcessor/EmbeddedPaymentProcessor.php:79
    197 #: modules.local/hosted-payment/src/PaymentProcessor/HostedPaymentProcessor.php:90
    198 #: modules/inpsyde/payoneer-embedded-payment/src/PaymentProcessor/EmbeddedPaymentProcessor.php:79
    199 #: modules/inpsyde/payoneer-hosted-payment/src/PaymentProcessor/HostedPaymentProcessor.php:90
     196#: modules.local/embedded-payment/src/PaymentProcessor/EmbeddedPaymentProcessor.php:69
     197#: modules.local/hosted-payment/src/PaymentProcessor/HostedPaymentProcessor.php:78
     198#: modules/inpsyde/payoneer-embedded-payment/src/PaymentProcessor/EmbeddedPaymentProcessor.php:69
     199#: modules/inpsyde/payoneer-hosted-payment/src/PaymentProcessor/HostedPaymentProcessor.php:78
    200200msgid "Payment failed. Please attempt the payment again or contact the shop admin. This issue has been logged."
    201201msgstr ""
    202202
    203203#. translators: Order note added when processing an order in embedded flow
    204 #: modules.local/embedded-payment/src/PaymentProcessor/EmbeddedPaymentProcessor.php:109
    205 #: modules/inpsyde/payoneer-embedded-payment/src/PaymentProcessor/EmbeddedPaymentProcessor.php:109
     204#: modules.local/embedded-payment/src/PaymentProcessor/EmbeddedPaymentProcessor.php:99
     205#: modules/inpsyde/payoneer-embedded-payment/src/PaymentProcessor/EmbeddedPaymentProcessor.php:99
    206206msgid "Backend processing finished, frontend processing is about to start."
    207207msgstr ""
     
    219219
    220220#. translators: Order note added when processing an order in hosted flow
    221 #: modules.local/hosted-payment/src/PaymentProcessor/HostedPaymentProcessor.php:122
    222 #: modules/inpsyde/payoneer-hosted-payment/src/PaymentProcessor/HostedPaymentProcessor.php:122
     221#: modules.local/hosted-payment/src/PaymentProcessor/HostedPaymentProcessor.php:110
     222#: modules/inpsyde/payoneer-hosted-payment/src/PaymentProcessor/HostedPaymentProcessor.php:110
    223223msgid "The customer is being redirected to the hosted payment page."
    224224msgstr ""
     
    326326
    327327#. translators: %1$s is replaced with transaction Long ID
    328 #: modules.local/payment-methods/inc/services.php:589
    329 #: modules/inpsyde/payoneer-payment-methods/inc/services.php:589
     328#: modules.local/payment-methods/inc/services.php:582
     329#: modules/inpsyde/payoneer-payment-methods/inc/services.php:582
    330330#, php-format
    331331msgid "Refunded by Payoneer Checkout - long ID: %1$s"
     
    353353
    354354#: modules.local/settings/inc/fields.php:53
    355 #: modules.local/status-report/inc/services.php:42
     355#: modules.local/status-report/inc/services.php:49
    356356#: modules/inpsyde/payoneer-settings/inc/fields.php:53
    357 #: modules/inpsyde/payoneer-status-report/inc/services.php:42
     357#: modules/inpsyde/payoneer-status-report/inc/services.php:49
    358358msgid "API username"
    359359msgstr ""
     
    438438msgstr ""
    439439
    440 #: modules.local/status-report/inc/services.php:33
    441 #: modules/inpsyde/payoneer-status-report/inc/services.php:33
     440#. translators: Title of the settings section
     441#: modules.local/status-report/inc/fields.php:16
     442#: modules/inpsyde/payoneer-status-report/inc/fields.php:16
     443msgid "System Report"
     444msgstr ""
     445
     446#. translators: Name of the opt-in setting (displayed on left side)
     447#: modules.local/status-report/inc/fields.php:22
     448#: modules/inpsyde/payoneer-status-report/inc/fields.php:22
     449msgid "Automated Troubleshooting"
     450msgstr ""
     451
     452#. translators: Label of the opt-in field (displayed next to the checkbox)
     453#: modules.local/status-report/inc/fields.php:24
     454#: modules/inpsyde/payoneer-status-report/inc/fields.php:24
     455msgid "Enable"
     456msgstr ""
     457
     458#. translators: Description of the opt-in setting (displayed below the checkbox)
     459#: modules.local/status-report/inc/fields.php:27
     460#: modules/inpsyde/payoneer-status-report/inc/fields.php:27
     461msgid "When \"Enable\" is checked, Payoneer support can remotely collect system information to help resolve issues, if they arise, without interrupting you.<br/>When \"Enable\" is unchecked, Payoneer support will need to request information manually from you, which could slow down the troubleshooting process and might delay problem resolution.<br/>We therefore recommend to keep \"Enable\" checked."
     462msgstr ""
     463
     464#: modules.local/status-report/inc/services.php:40
     465#: modules/inpsyde/payoneer-status-report/inc/services.php:40
    442466msgid "Shop country code"
    443467msgstr ""
    444468
    445 #: modules.local/status-report/inc/services.php:35
    446 #: modules/inpsyde/payoneer-status-report/inc/services.php:35
     469#: modules.local/status-report/inc/services.php:42
     470#: modules/inpsyde/payoneer-status-report/inc/services.php:42
    447471msgid "Country / State value on Settings / General / Store Address."
    448472msgstr ""
    449473
    450 #: modules.local/status-report/inc/services.php:47
    451 #: modules/inpsyde/payoneer-status-report/inc/services.php:47
     474#: modules.local/status-report/inc/services.php:54
     475#: modules/inpsyde/payoneer-status-report/inc/services.php:54
    452476msgid "Payment flow"
    453477msgstr ""
    454478
    455 #: modules.local/status-report/inc/services.php:49
    456 #: modules/inpsyde/payoneer-status-report/inc/services.php:49
     479#: modules.local/status-report/inc/services.php:56
     480#: modules/inpsyde/payoneer-status-report/inc/services.php:56
    457481msgid "Displays whether a plugin is using a hosted or an embedded payment flow"
    458482msgstr ""
  • payoneer-checkout/trunk/modules/inpsyde/payment-gateway/CHANGELOG.md

    r3260742 r3321269  
     1## [2.7.1](https://github.com/inpsyde/payment-gateway/compare/2.7.0...2.7.1) (2025-06-20)
     2
     3
     4### Bug Fixes
     5
     6* 🔧 Change WooCommerce hook from `woocommerce_blocks_loaded` to `woocommerce_init` ([#50](https://github.com/inpsyde/payment-gateway/issues/50)) ([b9919e8](https://github.com/inpsyde/payment-gateway/commit/b9919e8f98dcf8cee99b2dfe0cdbdc89f47c641b))
     7
     8# [2.7.0](https://github.com/inpsyde/payment-gateway/compare/2.6.0...2.7.0) (2025-04-02)
     9
     10
     11### Bug Fixes
     12
     13* Add id in ContentField ([a3747d9](https://github.com/inpsyde/payment-gateway/commit/a3747d90f9b804598158289434f41a2f8b32ef1b))
     14
     15
     16### Features
     17
     18* Add render_directly option in ContentField ([6becaaf](https://github.com/inpsyde/payment-gateway/commit/6becaaf304cbe676f648f40b769ceccdfb8b36a6))
     19
     20# [2.6.0](https://github.com/inpsyde/payment-gateway/compare/2.5.0...2.6.0) (2025-03-14)
     21
     22
     23### Features
     24
     25* Allow to override savedTokenComponent in blocks ([#48](https://github.com/inpsyde/payment-gateway/issues/48)) ([11d99eb](https://github.com/inpsyde/payment-gateway/commit/11d99ebf4fff9272884c87bac89055148d3b09a8))
     26
     27# [2.5.0](https://github.com/inpsyde/payment-gateway/compare/2.4.1...2.5.0) (2025-03-14)
     28
     29
     30### Bug Fixes
     31
     32* 📝 Remove redundant `get_form_fields` method and streamline form fields handling ([#47](https://github.com/inpsyde/payment-gateway/issues/47)) ([0b17b89](https://github.com/inpsyde/payment-gateway/commit/0b17b89e26460ba0e02e10fe559e61823f1e5051)), closes [#123](https://github.com/inpsyde/payment-gateway/issues/123)
     33
     34
     35### Features
     36
     37* Add support for plugin_slug property ([#45](https://github.com/inpsyde/payment-gateway/issues/45)) ([d7fd64c](https://github.com/inpsyde/payment-gateway/commit/d7fd64c96b649d14796368b76ca86fb4b7ece525))
     38
    139## [2.4.1](https://github.com/inpsyde/payment-gateway/compare/2.4.0...2.4.1) (2025-02-26)
    240
  • payoneer-checkout/trunk/modules/inpsyde/payment-gateway/assets/js/frontend/blocks.asset.php

    r3260742 r3321269  
    33namespace Syde\Vendor;
    44
    5 return array('dependencies' => array('react', 'wc-blocks-registry', 'wc-settings', 'wp-hooks', 'wp-html-entities', 'wp-i18n'), 'version' => 'd2b7cb451e648fd13cd7');
     5return array('dependencies' => array('react', 'wc-blocks-registry', 'wc-settings', 'wp-hooks', 'wp-html-entities', 'wp-i18n'), 'version' => 'e765912913b16a921729');
  • payoneer-checkout/trunk/modules/inpsyde/payment-gateway/assets/js/frontend/blocks.js

    r3260742 r3321269  
    1 (()=>{"use strict";const e=window.React,t=window.wp.i18n,n=window.wc.wcBlocksRegistry,a=window.wp.htmlEntities,l=window.wc.wcSettings,o=window.wp.hooks;inpsydeGateways.forEach((c=>{const r=(0,l.getSetting)(`${c}_data`,{}),s=`${c}_checkout_fields`,i=`${c}_payment_method_icons`,d=(0,t.__)("Syde Payment Gateway","syde-payment-gateway"),m=(0,a.decodeEntities)(r.title)||d,w=t=>{const[n,l]=(0,e.useState)([]);if((0,e.useEffect)((()=>{l(o.defaultHooks.applyFilters(s,[]))}),[]),!Array.isArray(n)||!n.length){const t=()=>(0,a.decodeEntities)(r.description||"");return(0,e.createElement)(t,null)}return(0,e.createElement)(e.Fragment,null,n.map((n=>(0,e.createElement)(n,{...t}))))},u={name:c,label:(0,e.createElement)((t=>{const{PaymentMethodLabel:n,PaymentMethodIcons:a}=t.components;return(0,e.createElement)(e.Fragment,null,(0,e.createElement)(n,{text:m}),(0,e.createElement)(a,{icons:o.defaultHooks.applyFilters(i,r.icons)}))}),null),content:(0,e.createElement)(w,null),edit:(0,e.createElement)(w,null),icons:r.icons,canMakePayment:()=>!0,ariaLabel:m,supports:{features:r.supports}};r.placeOrderButtonLabel&&(u.placeOrderButtonLabel=r.placeOrderButtonLabel),(0,n.registerPaymentMethod)(u)}))})();
     1(()=>{"use strict";const e=window.React,t=window.wp.i18n,n=window.wc.wcBlocksRegistry,a=window.wp.htmlEntities,l=window.wc.wcSettings,r=window.wp.hooks;inpsydeGateways.forEach(o=>{const s=(0,l.getSetting)(`${o}_data`,{}),c=`${o}_checkout_fields`,i=`${o}_saved_token_fields`,d=`${o}_payment_method_icons`,m=(0,t.__)("Syde Payment Gateway","syde-payment-gateway"),u=(0,a.decodeEntities)(s.title)||m,p=t=>{const[n,l]=(0,e.useState)([]);if((0,e.useEffect)(()=>{l(r.defaultHooks.applyFilters(c,[]))},[]),!Array.isArray(n)||!n.length){const t=()=>(0,a.decodeEntities)(s.description||"");return(0,e.createElement)(t,null)}return(0,e.createElement)(e.Fragment,null,n.map(n=>(0,e.createElement)(n,{...t})))},w={name:o,label:(0,e.createElement)(t=>{const{PaymentMethodLabel:n,PaymentMethodIcons:a}=t.components;return(0,e.createElement)(e.Fragment,null,(0,e.createElement)(n,{text:u}),(0,e.createElement)(a,{icons:r.defaultHooks.applyFilters(d,s.icons)}))},null),content:(0,e.createElement)(p,null),edit:(0,e.createElement)(p,null),savedTokenComponent:(0,e.createElement)(t=>{const[n,a]=(0,e.useState)([]);return(0,e.useEffect)(()=>{a(r.defaultHooks.applyFilters(i,[]))},[]),Array.isArray(n)&&n.length?(0,e.createElement)(e.Fragment,null,n.map(n=>(0,e.createElement)(n,{...t}))):null},null),icons:s.icons,canMakePayment:()=>!0,ariaLabel:u,supports:{features:s.supports}};s.placeOrderButtonLabel&&(w.placeOrderButtonLabel=s.placeOrderButtonLabel),(0,n.registerPaymentMethod)(w)})})();
  • payoneer-checkout/trunk/modules/inpsyde/payment-gateway/src/Fields/ContentField.php

    r3124685 r3321269  
    1919        $data = array_merge(['title' => '', 'disabled' => \false, 'class' => '', 'css' => '', 'placeholder' => '', 'type' => 'text', 'desc_tip' => \false, 'description' => '', 'custom_attributes' => []], $fieldConfig);
    2020        $hasTitle = !empty($data['title']);
     21        $renderDirectly = $data['render_directly'] ?? \false;
    2122        // phpcs:disable WordPress.Security.EscapeOutput.OutputNotEscaped
    2223        ob_start();
    2324        ?>
    24         <tr valign="top">
     25        <tr valign="top" id="<?php
     26        echo $fieldKey;
     27        ?>">
    2528            <?php
    2629        if ($hasTitle) {
     
    4851        ?>">
    4952                <?php
    50         echo $gateway->get_description_html($data);
     53        echo $renderDirectly ? wp_kses_post((string) $data['description']) : $gateway->get_description_html($data);
    5154        ?>
    5255            </td>
  • payoneer-checkout/trunk/modules/inpsyde/payment-gateway/src/PaymentGateway.php

    r3260742 r3321269  
    5555        unset($this->method_description);
    5656        unset($this->icon);
     57        unset($this->form_fields);
    5758        add_action('woocommerce_update_options_payment_gateways_' . $this->id, [$this, 'process_admin_options']);
    5859        add_action('woocommerce_settings_checkout', [$this, 'display_errors']);
     
    380381     * @inheritDoc
    381382     */
    382     public function get_form_fields()
    383     {
    384         if (!$this->form_fields) {
    385             $this->form_fields = $this->locate('form_fields');
    386         }
    387         return parent::get_form_fields();
    388     }
    389     /**
    390      * @inheritDoc
    391      */
    392383    public function get_option_key()
    393384    {
     
    474465            return $this->locate($name);
    475466        }
     467        if ($name === 'plugin_slug') {
     468            return $this->locate($name);
     469        }
    476470        if ($name === 'icon') {
    477471            return $this->locateWithFallback($name, null);
    478472        }
     473        if ($name === 'form_fields') {
     474            return $this->locate('form_fields');
     475        }
    479476        return $this->{$name};
    480477    }
  • payoneer-checkout/trunk/modules/inpsyde/payment-gateway/src/PaymentGatewayModule.php

    r3260742 r3321269  
    1212use Syde\Vendor\Inpsyde\Modularity\Module\ModuleClassNameIdTrait;
    1313use Syde\Vendor\Inpsyde\Modularity\Module\ServiceModule;
     14use Syde\Vendor\Inpsyde\Modularity\Package;
     15use Syde\Vendor\Inpsyde\Modularity\Properties\PluginProperties;
    1416use Syde\Vendor\Inpsyde\PaymentGateway\Fields\ContentField;
    1517use Syde\Vendor\Inpsyde\PaymentGateway\Method\PaymentMethodDefinition;
     
    3133    public function services(): array
    3234    {
    33         return array_merge(['payment_gateways.assets_url' => function (): string {
    34             return $this->getPluginFileUrlFromAbsolutePath(dirname(__DIR__) . '/assets');
    35         }, 'payment_gateways.assets_path' => static function (): string {
    36             return dirname(__DIR__) . '/assets';
    37         }, 'payment_gateways.noop_payment_request_validator' => static function (): PaymentRequestValidatorInterface {
    38             return new NoopPaymentRequestValidator();
    39         }, 'payment_gateways.noop_payment_processor' => static function (): PaymentProcessorInterface {
    40             return new NoopPaymentProcessor();
    41         }, 'payment_gateways.noop_refund_processor' => static function (): RefundProcessorInterface {
    42             return new NoopRefundProcessor();
    43         }, 'payment_gateways.settings_field_renderer.content' => static function (): SettingsFieldRendererInterface {
    44             return new ContentField();
    45         }, 'payment_gateways' => function (): array {
    46             $gateways = [];
    47             foreach ($this->paymentMethods as $paymentMethod) {
    48                 $gateways[] = $paymentMethod->id();
    49             }
    50             return $gateways;
    51         }, 'payment_gateways.methods_supporting_blocks' => static function (ContainerInterface $container): array {
    52             $supported = [];
    53             $allMethods = $container->get('payment_gateways');
    54             foreach ($allMethods as $method) {
    55                 $registerBlocksKey = 'payment_gateway.' . $method . '.register_blocks';
    56                 $shouldRegister = \true;
    57                 if ($container->has($registerBlocksKey)) {
    58                     $shouldRegister = (bool) $container->get($registerBlocksKey);
     35        return array_merge([
     36            /**
     37             * WooCommerce (>= 9.6) derives the payment gateway plugin slug via reflection
     38             * (see \Automattic\WooCommerce\Internal\Admin\Settings\PaymentProviders\PaymentGateway::get_plugin_slug)
     39             * but first checks if the plugin_slug property is set. By setting it explicitly here, we
     40             * prevent potential namespace conflicts when multiple plugins use this payment gateway library.
     41             */
     42            'payment_gateways.plugin_slug' => static function (ContainerInterface $container): string {
     43                /** @var PluginProperties $properties */
     44                $pluginProperties = $container->get(Package::PROPERTIES);
     45                return $pluginProperties->baseName();
     46            },
     47            'payment_gateways.assets_url' => function (): string {
     48                return $this->getPluginFileUrlFromAbsolutePath(dirname(__DIR__) . '/assets');
     49            },
     50            'payment_gateways.assets_path' => static function (): string {
     51                return dirname(__DIR__) . '/assets';
     52            },
     53            'payment_gateways.noop_payment_request_validator' => static function (): PaymentRequestValidatorInterface {
     54                return new NoopPaymentRequestValidator();
     55            },
     56            'payment_gateways.noop_payment_processor' => static function (): PaymentProcessorInterface {
     57                return new NoopPaymentProcessor();
     58            },
     59            'payment_gateways.noop_refund_processor' => static function (): RefundProcessorInterface {
     60                return new NoopRefundProcessor();
     61            },
     62            'payment_gateways.settings_field_renderer.content' => static function (): SettingsFieldRendererInterface {
     63                return new ContentField();
     64            },
     65            'payment_gateways' => function (): array {
     66                $gateways = [];
     67                foreach ($this->paymentMethods as $paymentMethod) {
     68                    $gateways[] = $paymentMethod->id();
    5969                }
    60                 if ($shouldRegister) {
    61                     $supported[] = $method;
     70                return $gateways;
     71            },
     72            'payment_gateways.methods_supporting_blocks' => static function (ContainerInterface $container): array {
     73                $supported = [];
     74                $allMethods = $container->get('payment_gateways');
     75                foreach ($allMethods as $method) {
     76                    $registerBlocksKey = 'payment_gateway.' . $method . '.register_blocks';
     77                    $shouldRegister = \true;
     78                    if ($container->has($registerBlocksKey)) {
     79                        $shouldRegister = (bool) $container->get($registerBlocksKey);
     80                    }
     81                    if ($shouldRegister) {
     82                        $supported[] = $method;
     83                    }
    6284                }
    63             }
    64             return $supported;
    65         }, 'payment_gateways.required_services' => static function (): array {
    66             return ['payment_gateway.%s.payment_request_validator', 'payment_gateway.%s.payment_processor'];
    67         }, 'payment_gateways.validator' => static function (ContainerInterface $container): PaymentGatewayValidator {
    68             $requiredServices = $container->get('payment_gateways.required_services');
    69             assert(is_array($requiredServices));
    70             return new PaymentGatewayValidator($container, $requiredServices);
    71         }, 'payment_gateways.i18n' => static fn(ContainerInterface $container): I18n => new I18n($container), 'payment_gateways.i18n.messages' => static fn(): array => ['refund_order_not_found' => static fn(array $params): string => sprintf(
    72             /* translators: %1$s is replaced with the actual order ID. */
    73             __('Failed to process the refund: the order with ID %1$s not found', 'syde-payment-gateway'),
    74             (string) $params['orderId']
    75         ), 'refund_failed' => __('Failed to refund the order payment', 'syde-payment-gateway'), 'payment_method_not_available' => __('Payment method not available. Please select another payment method.', 'syde-payment-gateway')]], $this->providePaymentMethodServices(...$this->paymentMethods));
     85                return $supported;
     86            },
     87            'payment_gateways.required_services' => static function (): array {
     88                return ['payment_gateway.%s.payment_request_validator', 'payment_gateway.%s.payment_processor'];
     89            },
     90            'payment_gateways.validator' => static function (ContainerInterface $container): PaymentGatewayValidator {
     91                $requiredServices = $container->get('payment_gateways.required_services');
     92                assert(is_array($requiredServices));
     93                return new PaymentGatewayValidator($container, $requiredServices);
     94            },
     95            'payment_gateways.i18n' => static fn(ContainerInterface $container): I18n => new I18n($container),
     96            'payment_gateways.i18n.messages' => static fn(): array => ['refund_order_not_found' => static fn(array $params): string => sprintf(
     97                /* translators: %1$s is replaced with the actual order ID. */
     98                __('Failed to process the refund: the order with ID %1$s not found', 'syde-payment-gateway'),
     99                (string) $params['orderId']
     100            ), 'refund_failed' => __('Failed to refund the order payment', 'syde-payment-gateway'), 'payment_method_not_available' => __('Payment method not available. Please select another payment method.', 'syde-payment-gateway')],
     101        ], $this->providePaymentMethodServices(...$this->paymentMethods));
    76102    }
    77103    public function run(ContainerInterface $container): bool
     
    93119         *
    94120         */
    95         add_action('woocommerce_blocks_loaded', function () use ($container): void {
     121        add_action('woocommerce_init', function () use ($container): void {
    96122            if (!class_exists(AbstractPaymentMethodType::class)) {
    97123                return;
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-embedded-payment/assets/payoneer-checkout.asset.php

    r3305047 r3321269  
    33namespace Syde\Vendor;
    44
    5 return array('dependencies' => array('jquery', 'react', 'wc-blocks-data-store', 'wp-api-fetch', 'wp-data', 'wp-hooks'), 'version' => '9ca74476643627ca1471');
     5return array('dependencies' => array('jquery', 'react', 'wc-blocks-data-store', 'wp-api-fetch', 'wp-data', 'wp-hooks'), 'version' => 'e1e588052347528f5d49');
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-embedded-payment/assets/payoneer-checkout.js

    r3305047 r3321269  
    1 !function(){"use strict";var e={20:function(e,t,o){var n=o(609),a=Symbol.for("react.element"),r=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),c=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};t.jsx=function(e,t,o){var n,i={},d=null,l=null;for(n in void 0!==o&&(d=""+o),void 0!==t.key&&(d=""+t.key),void 0!==t.ref&&(l=t.ref),t)r.call(t,n)&&!s.hasOwnProperty(n)&&(i[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps)void 0===i[n]&&(i[n]=t[n]);return{$$typeof:a,type:e,key:d,ref:l,props:i,_owner:c.current}}},609:function(e){e.exports=window.React},848:function(e,t,o){e.exports=o(20)}},t={};function o(n){var a=t[n];if(void 0!==a)return a.exports;var r=t[n]={exports:{}};return e[n](r,r.exports,o),r.exports}o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,{a:t}),t},o.d=function(e,t){for(var n in t)o.o(t,n)&&!o.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var n={};o.r(n),o.d(n,{addComponent:function(){return O},initPayoneerComponents:function(){return k},mountComponents:function(){return P},onBeforeError:function(){return C},onComponentListChange:function(){return M},onPaymentDeclined:function(){return L},onValidationInfo:function(){return A},pay:function(){return N},reboot:function(){return v},releaseOnHoldOrder:function(){return x},removeComponent:function(){return I},setActivePaymentMethod:function(){return b},setEnv:function(){return D},setForceHostedFlow:function(){return R},setIsValid:function(){return F},setLongId:function(){return g},setOnPaymentDeclinedNonce:function(){return H},setOrderId:function(){return V},setSdkState:function(){return T}});var a={};o.r(a),o.d(a,{getEnv:function(){return W},getExtensionData:function(){return G},getLongId:function(){return q},getSdk:function(){return U},getSdkIntegrity:function(){return $},getSdkVersion:function(){return X}});var r=window.jQuery,c=o.n(r);const{paymentFieldsComponentAttribute:s}=window.PayoneerData,i=()=>document.querySelector('.woocommerce-checkout input[name="payment_method"]:checked'),d=()=>i()?.id,l=()=>{return e=d(),/^payment_method_payoneer-(checkout|afterpay)/i.test(e);var e},p=()=>"1"===window.PayoneerData.isPayForOrder,y=()=>{i()?.focus()};var u=window.wp.data;const E={SET_EXTENSION_DATA:"SET_EXTENSION_DATA",SET_LONG_ID:"SET_LONG_ID",SET_LIST_URL:"SET_LIST_URL",SET_ENV:"SET_ENV",SET_SDK:"SET_SDK",SET_SDK_VERSION:"SET_SDK_VERSION",SET_SDK_INTEGRITY:"SET_SDK_INTEGRITY",SET_SDK_STATE:"SET_SDK_STATE",ADD_COMPONENT:"ADD_COMPONENT",REMOVE_COMPONENT:"REMOVE_COMPONENT",MOUNT_COMPONENTS:"MOUNT_COMPONENTS",PAY:"PAY",SET_ACTIVE_PAYMENT_METHOD:"SET_ACTIVE_PAYMENT_METHOD",SET_FORCE_HOSTED_FLOW:"SET_FORCE_HOSTED_FLOW",SET_IS_VALID:"SET_IS_VALID",SET_ORDER_ID:"SET_ORDER_ID",SET_ON_PAYMENT_DECLINED_NONCE:"SET_ON_PAYMENT_DECLINED_NONCE"},_={activePaymentMethod:"",longId:null,env:null,sdkState:"UNINITIALIZED",forceHostedFlow:!0,isValid:!1,availableDropInComponents:[]};const S=e=>({"payoneer-checkout":"cards","payoneer-afterpay":"afterpay"}[e]),{paymentFieldsComponentAttribute:m}=window.PayoneerData,w=(e,t)=>{for(const[o,n]of Object.entries(e)){const e=h(o);e instanceof Element&&t.isAvailable(o)&&n.mount(e)}},h=function(e){return document.querySelector(`[${m}=${e}]`)};var f=window.wp.hooks;const g=e=>async({select:t,resolveSelect:o,dispatch:n})=>{const a=await o.getSdk();await a.updateLongId(e),n({type:E.SET_LONG_ID,payload:e})},T=e=>({type:E.SET_SDK_STATE,payload:e});function D(e){return{type:E.SET_ENV,payload:e}}const O=e=>async({select:t,resolveSelect:o,dispatch:n})=>{const a=await o.getSdk();if(console.log(a),!a.isDroppedIn(e)&&"object"==typeof h(e))try{const t={name:e,component:a.dropIn(e,{hidePaymentButton:!0})};console.log("New component",t),n({type:E.ADD_COMPONENT,payload:t}),w({[t.name]:t.component},a)}catch(t){console.error(`Failed to drop in component ${e}. Error details: ${t}`)}};function I(e){return{type:E.REMOVE_COMPONENT,payload:e}}const k=()=>async({select:e,resolveSelect:t,dispatch:o})=>{const n=await t.getSdk(),a=await t.getLongId();await n.updateLongId(a),await o.mountComponents()},v=()=>async({select:e,resolveSelect:t,dispatch:o})=>{f.defaultHooks.doAction("payoneer.webSdk.reboot"),wp.data.dispatch("wc/store/cart").invalidateResolutionForStore(),o.invalidateResolutionForStore(),await o.mountComponents()},P=()=>async({select:e,resolveSelect:t,dispatch:o})=>{const n=await t.getSdk(),a=e.getAvailableDropInComponents();console.log("Mounting components",a),w(a,n)},N=()=>({select:e,dispatch:t})=>{const o=e.getAvailableDropInComponents(),n=e.getActivePaymentMethod(),a=o[S(n)];a?a.pay():console.log("Component not found.")},C=(e,t,o)=>async({select:n,dispatch:a})=>(a.setSdkState(e.state),console.error("WebSDK error:",{sdk:e,component:t,data:o}),["SYSTEM_FAILURE"].includes(o?.interaction?.reason)?(a.setForceHostedFlow(!0),!0):f.defaultHooks.applyFilters("payoneer.webSdk.onSdkError",!1,e,t,o)),L=(e,t,o)=>async({select:n,dispatch:a})=>f.defaultHooks.applyFilters("payoneer.webSdk.onPaymentDeclined",!0,e,t,o),M=(e,t)=>async({select:o,dispatch:n})=>{console.log("onComponentListChange",e,t),t.addedComponents.forEach((e=>{n.addComponent(e)})),t.removedComponents.forEach((e=>{n.removeComponent(e)}))},A=(e,t,o)=>async({select:e,dispatch:n})=>{console.log(t,o),n.setIsValid(o.valid)},b=e=>async({dispatch:t})=>{console.log("Setting active payment method",e),t.mountComponents(),t({type:E.SET_ACTIVE_PAYMENT_METHOD,payload:e})};function R(e){return console.log("Setting hosted flow override flag",e),{type:E.SET_FORCE_HOSTED_FLOW,payload:e}}function F(e){return{type:E.SET_IS_VALID,payload:e}}const H=e=>({dispatch:t})=>{t({type:E.SET_ON_PAYMENT_DECLINED_NONCE,payload:e})},V=e=>({dispatch:t})=>{t({type:E.SET_ORDER_ID,payload:e})},x=e=>async({dispatch:t})=>{const o=window.wc_checkout_params.wc_ajax_url.toString().replace("%%endpoint%%","payoneer-checkout-payment-declined"),n=o.includes("?")?"&":"?",a=o+n+"_ajax_nonce="+window.PayoneerData.onPaymentDeclinedNonce;return new Promise(((o,n)=>{c().ajax({type:"POST",url:a,xhrFields:{withCredentials:!0},data:e,dataType:"json"}).success((e=>{t.setOnPaymentDeclinedNonce(e.nonce),o(e)})).catch((e=>{console.log(e),n(e)}))}))};var j=window.wp.apiFetch,K=o.n(j);const{websdkStyles:Y}=PayoneerData,U=()=>async({resolveSelect:e,dispatch:t})=>{const o=await e.getEnv(),n=await e.getSdkVersion(),a=await e.getSdkIntegrity(),r=await e.getLongId(),c=await(s={env:o,sdkVersion:n,sdkIntegrity:a,onBeforeError:async(e,o,n)=>await t.onBeforeError(e,o,n),onPaymentDeclined:async(e,o,n)=>await t.onPaymentDeclined(e,o,n),onComponentListChange:async(e,o)=>await t.onComponentListChange(e,o),onValidationInfo:async(e,o,n)=>await t.onValidationInfo(e,o,n),preload:["cards"],styles:Y},window.Payoneer?.CheckoutWeb?window.Payoneer.CheckoutWeb(s):new Promise(((e,t)=>{const o=document.createElement("script");o.src=((e,t)=>{const o=t?`-${t}`:"";return new URL(window.PayoneerData.webSdkUmdUrlTemplate?.replace("<env>",e)?.replace("<version>",o))})(s.env,s.sdkVersion),o.onload=e,o.onerror=t,s.sdkVersion&&s.sdkIntegrity&&(o.integrity=s.sdkIntegrity,o.crossOrigin="anonymous"),document.head.appendChild(o)})).then((()=>window.Payoneer.CheckoutWeb(s))));var s;if("LOADING"===c.state){const e=async()=>await new Promise((e=>{const t=setInterval((()=>{"LOADING"!==c.state&&(e(c.state),clearInterval(t))}),1e3)}));await e()}await c.updateLongId(r),await t.setForceHostedFlow(!1),await t.setSdkState(c.state),await t({type:E.SET_SDK,payload:c})},G=()=>async({dispatch:e})=>{const t=await K()({path:"/wc/store/v1/cart#skipPreloadingMiddleware",method:"GET",cache:"no-store",parse:!1}),o=(await t.json()).extensions["payoneer-checkout"];console.log("Payoneer Extension Data: ",o),await e({type:E.SET_EXTENSION_DATA,payload:o}),f.defaultHooks.doAction("payoneer.checkout.onReceiveExtensionData",o)},q=()=>async({resolveSelect:e,dispatch:t})=>{const o=await e.getExtensionData();await t({type:E.SET_LONG_ID,payload:o.longId})},W=()=>async({resolveSelect:e,dispatch:t})=>{const o=await e.getExtensionData();await t({type:E.SET_ENV,payload:o.environment})},X=()=>async({resolveSelect:e,dispatch:t})=>{const o=await e.getExtensionData();await t({type:E.SET_SDK_VERSION,payload:o.sdkVersion})},$=()=>async({resolveSelect:e,dispatch:t})=>{const o=await e.getExtensionData();await t({type:E.SET_SDK_INTEGRITY,payload:o.sdkIntegrity})};const B="payoneer-checkout",Q=(0,u.createReduxStore)(B,{reducer:(e=_,t)=>{switch(t.type){case E.SET_EXTENSION_DATA:return{...e,extension:t.payload};case E.SET_LONG_ID:return{...e,longId:t.payload};case E.SET_LIST_URL:return{...e,listUrl:t.payload};case E.SET_ENV:return{...e,env:t.payload};case E.SET_SDK:return{...e,sdk:t.payload};case E.SET_SDK_VERSION:return{...e,sdkVersion:t.payload};case E.SET_SDK_INTEGRITY:return{...e,sdkIntegrity:t.payload};case E.SET_SDK_STATE:return{...e,sdkState:t.payload};case E.SET_ACTIVE_PAYMENT_METHOD:return{...e,activePaymentMethod:t.payload};case E.SET_FORCE_HOSTED_FLOW:return{...e,forceHostedFlow:t.payload};case E.SET_IS_VALID:return{...e,isValid:t.payload};case E.SET_ORDER_ID:return{...e,orderId:t.payload};case E.SET_ON_PAYMENT_DECLINED_NONCE:return{...e,onPaymentDeclinedNonce:t.payload};case E.ADD_COMPONENT:return{...e,availableDropInComponents:{...e.availableDropInComponents,[t.payload.name]:t.payload.component}};case E.REMOVE_COMPONENT:let o={...e.availableDropInComponents};return delete o[t.payload.name],{...e,availableDropInComponents:o};default:return e}},actions:n,selectors:{getExtensionData:e=>e.extension,getLongId:e=>e.longId,getEnv:e=>e.env,getSdkVersion:e=>e.sdkVersion,getSdkIntegrity:e=>e.sdkIntegrity,getSdk:e=>e.sdk,isHostedModeForced:e=>e.forceHostedFlow,getIsValid:e=>"payoneer-checkout"!==e.activePaymentMethod||e.isValid,getActivePaymentMethod:e=>e.activePaymentMethod,getAvailableDropInComponents:e=>e.availableDropInComponents,getOrderId:e=>e.orderId,getOnPaymentDeclinedNonce:e=>e.onPaymentDeclinedNonce},resolvers:a});(0,u.register)(Q);const z="x-payoneer-checkout-force-hosted-flow",Z="x-payoneer-is-payment-checkout",J=()=>{const e={[z]:String((0,u.select)(B).isHostedModeForced()),[Z]:p&&new URLSearchParams(window.location.search).get("key")||""};return f.defaultHooks.applyFilters("payoneer.http.customHeaders",e)};f.defaultHooks.addAction("payoneer.checkout.onReceiveExtensionData","payoneer/setupCustomHttpHeaders",(()=>{f.defaultHooks.addFilter("payoneer.http.customHeaders","payoneer/setupCustomHttpHeaders",(function(e){return e["x-payoneer-long-id"]=String((0,u.select)(B).getLongId()),e}))}));var ee=window.wc.wcBlocksData;const te=()=>{const e=function(){const e=null!==(t=document.querySelector('.woocommerce-checkout input[name="payment_method"]:checked').value)&&void 0!==t?t:"";var t;(0,u.dispatch)(B).setActivePaymentMethod(e)};jQuery(document.body).on("payment_method_selected",e),e()};var oe=o(609),ne=o(848);const ae=()=>(0,u.dispatch)(B).initPayoneerComponents(),re=()=>(0,u.dispatch)(B).pay(),ce=()=>(0,u.dispatch)(B).reboot(),se=(0,u.withSelect)(((e,t)=>{const o=e(B),{activePaymentMethod:n,eventRegistration:a}=t;return{activePaymentMethod:n,eventRegistration:a,payWithPayoneer:re,initPayoneerComponents:ae,rebootPayoneer:ce,isValid:o.getIsValid()}}))((function({payWithPayoneer:e,initPayoneerComponents:t,paymentMethodData:o,rebootPayoneer:n,activePaymentMethod:a,eventRegistration:r,isValid:c}){const{onPaymentSetup:s,onCheckoutSuccess:i,onCheckoutFail:d}=r;(0,oe.useEffect)((()=>{t()}),[]),(0,oe.useEffect)((()=>i((({orderId:t})=>{(0,u.dispatch)(B).setOrderId(t),e()}))),[]),(0,oe.useEffect)((()=>d(n)),[]),(0,oe.useEffect)((()=>s((()=>c?{type:"success"}:{type:"failure",message:"Invalid payment fields"}))),[c,s,o]);const l=S(a);return(0,ne.jsx)("div",{className:`payment_method_${a}`,"data-component":l})})),ie=(0,u.select)(B);document.addEventListener("DOMContentLoaded",(async()=>{const e=window.fetch;if(window.fetch=async(...t)=>{let[o,n]=t;if(new URL(o,window.location.origin).origin!==window.location.origin)return e(o,n);const a=J();return console.log("Adding custom headers to fetch call",a),n=n&&n.headers?{...n,headers:{...n.headers,...a}}:{...n,headers:a},await e(o,n)},!window.XMLHttpRequest)return;const t=XMLHttpRequest.prototype.open,o=XMLHttpRequest.prototype.send;XMLHttpRequest.prototype.open=function(e,o,...n){this._isSameOrigin=new URL(o,window.location.origin).origin===window.location.origin,t.apply(this,[e,o,...n])},XMLHttpRequest.prototype.send=function(...e){const t=J();if(this._isSameOrigin){console.log("Adding custom headers to XMLHttpRequest call",t);for(const[e,o]of Object.entries(t))this.setRequestHeader(e,o)}o.apply(this,e)}}),!1),p()?(console.log("Loading payment checkout integration"),document.addEventListener("DOMContentLoaded",(()=>{te(),(0,u.dispatch)(B).setOnPaymentDeclinedNonce(PayoneerData.onPaymentDeclinedNonce);const e=c()("#order_review");f.defaultHooks.addFilter("payoneer.webSdk.onSdkError","payoneer/paymentCheckout",((e,t,o,n)=>{const{payOrderErrorFlag:a}=window.PayoneerData,r=new URL(document.location);return r.searchParams.set(a,!0),window.location.href=r.toString(),e})),wp.hooks.addFilter("payoneer.webSdk.onPaymentDeclined","payoneer/paymentCheckout",(async()=>(await wp.data.dispatch(B).releaseOnHoldOrder({longId:(0,u.select)(B).getLongId(),orderKey:new URLSearchParams(window.location.search).get("key")}),window.location.reload(),!1))),e.on("submit",(t=>{if(l()&&!(0,u.select)(B).isHostedModeForced()){if(t.preventDefault(),t.stopImmediatePropagation(),!(0,u.select)(B).getIsValid())try{y()}catch(e){console.error(e)}finally{return}var o;(o=e,o.block({message:null,overlayCSS:{background:"#fff",opacity:.6}}),c().ajax({type:"POST",url:window.wc_checkout_params.ajax_url,xhrFields:{withCredentials:!0},dataType:"json",data:{action:"payoneer_order_pay",fields:o.serialize(),params:new URL(document.location).searchParams.toString()}}).always((()=>o.unblock()))).then((()=>(0,u.dispatch)(B).pay())).catch((()=>{window.scrollTo(0,0),window.location.reload()}))}})),(0,u.dispatch)(B).mountComponents()}),!1)):"1"===window?.PayoneerData?.isBlockCheckout?(console.log("Loading classic checkout integration"),(()=>{let e;const t=(0,u.select)(ee.PAYMENT_STORE_KEY),o=()=>{const o=t.getActivePaymentMethod();e!==o&&((0,u.dispatch)(B).setActivePaymentMethod(o),e=o)};(0,u.subscribe)(o,ee.PAYMENT_STORE_KEY),o()})(),Array.isArray(inpsydeGateways)?inpsydeGateways.forEach((e=>{var t;t=e,wp.hooks.addFilter(`${t}_checkout_fields`,t,(e=>(e.push(se),e))),wp.hooks.addFilter("payoneer-checkout_payment_method_icons","payoneer-checkout",(e=>"payoneer-checkout"===ie.getActivePaymentMethod()?[]:e))})):console.error("window.inpsydeGateways not found"),document.addEventListener("DOMContentLoaded",(()=>{wp.hooks.addFilter("payoneer.webSdk.onPaymentDeclined","payoneer/blockCheckout",(()=>(wp.data.dispatch(B).releaseOnHoldOrder({longId:(0,u.select)(B).getLongId(),payoneerOrderId:(0,u.select)(B).getOrderId()}),window.location.reload(),!0)))}),!1)):(console.log("Loading classic checkout integration"),document.addEventListener("DOMContentLoaded",(()=>{te(),(0,u.dispatch)(B).setOnPaymentDeclinedNonce(PayoneerData.onPaymentDeclinedNonce);const e=c()("form.checkout");f.defaultHooks.addFilter("payoneer.webSdk.onSdkError","payoneer/shortcodeCheckout",((e,t,o,n)=>(wp.data.dispatch(B).reboot(),c()(document.body).trigger("update_checkout"),e))),wp.hooks.addFilter("payoneer.webSdk.onPaymentDeclined","payoneer/shortcodeCheckout",(()=>(wp.data.dispatch(B).releaseOnHoldOrder({longId:(0,u.select)(B).getLongId()}),!1))),c()(document.body).on("updated_checkout",(()=>(0,u.dispatch)(B).initPayoneerComponents())),e.on("checkout_place_order",(()=>{if((0,u.select)(B).getIsValid())return!0;try{y()}catch(e){console.error(e)}finally{return!1}})),e.on("checkout_place_order_success",((t,o)=>{if(l()&&!(0,u.select)(B).isHostedModeForced())return(0,u.dispatch)(B).pay(),o.redirect="#payoneer-redirect",setTimeout((()=>{e.removeClass("processing").unblock(),c().scroll_to_notices(c()((e=>{const t=".payment_box."+e;return document.querySelector(t)})(d())))}),1500),!1}))}),!1))}();
     1!function(){"use strict";var e={20:function(e,t,o){var n=o(609),a=Symbol.for("react.element"),r=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),c=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};t.jsx=function(e,t,o){var n,i={},d=null,l=null;for(n in void 0!==o&&(d=""+o),void 0!==t.key&&(d=""+t.key),void 0!==t.ref&&(l=t.ref),t)r.call(t,n)&&!s.hasOwnProperty(n)&&(i[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps)void 0===i[n]&&(i[n]=t[n]);return{$$typeof:a,type:e,key:d,ref:l,props:i,_owner:c.current}}},609:function(e){e.exports=window.React},848:function(e,t,o){e.exports=o(20)}},t={};function o(n){var a=t[n];if(void 0!==a)return a.exports;var r=t[n]={exports:{}};return e[n](r,r.exports,o),r.exports}o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,{a:t}),t},o.d=function(e,t){for(var n in t)o.o(t,n)&&!o.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var n={};o.r(n),o.d(n,{addComponent:function(){return O},initPayoneerComponents:function(){return k},mountComponents:function(){return P},onBeforeError:function(){return C},onComponentListChange:function(){return M},onPaymentDeclined:function(){return L},onValidationInfo:function(){return A},pay:function(){return N},reboot:function(){return v},releaseOnHoldOrder:function(){return x},removeComponent:function(){return I},setActivePaymentMethod:function(){return b},setEnv:function(){return D},setForceHostedFlow:function(){return R},setIsValid:function(){return F},setLongId:function(){return g},setOnPaymentDeclinedNonce:function(){return H},setOrderId:function(){return V},setSdkState:function(){return T}});var a={};o.r(a),o.d(a,{getEnv:function(){return W},getExtensionData:function(){return G},getLongId:function(){return q},getSdk:function(){return U},getSdkIntegrity:function(){return $},getSdkVersion:function(){return X}});var r=window.jQuery,c=o.n(r);const{paymentFieldsComponentAttribute:s}=window.PayoneerData,i=()=>document.querySelector('.woocommerce-checkout input[name="payment_method"]:checked'),d=()=>i()?.id,l=()=>{return e=d(),/^payment_method_payoneer-(checkout|afterpay)/i.test(e);var e},p=()=>"1"===window.PayoneerData.isPayForOrder,y=()=>{i()?.focus()};var u=window.wp.data;const E={SET_EXTENSION_DATA:"SET_EXTENSION_DATA",SET_LONG_ID:"SET_LONG_ID",SET_LIST_URL:"SET_LIST_URL",SET_ENV:"SET_ENV",SET_SDK:"SET_SDK",SET_SDK_VERSION:"SET_SDK_VERSION",SET_SDK_INTEGRITY:"SET_SDK_INTEGRITY",SET_SDK_STATE:"SET_SDK_STATE",ADD_COMPONENT:"ADD_COMPONENT",REMOVE_COMPONENT:"REMOVE_COMPONENT",MOUNT_COMPONENTS:"MOUNT_COMPONENTS",PAY:"PAY",SET_ACTIVE_PAYMENT_METHOD:"SET_ACTIVE_PAYMENT_METHOD",SET_FORCE_HOSTED_FLOW:"SET_FORCE_HOSTED_FLOW",SET_IS_VALID:"SET_IS_VALID",SET_ORDER_ID:"SET_ORDER_ID",SET_ON_PAYMENT_DECLINED_NONCE:"SET_ON_PAYMENT_DECLINED_NONCE"},_={activePaymentMethod:"",longId:null,env:null,sdkState:"UNINITIALIZED",forceHostedFlow:!0,isValid:!1,availableDropInComponents:[]};const S=e=>({"payoneer-checkout":"cards","payoneer-afterpay":"afterpay"}[e]),{paymentFieldsComponentAttribute:m}=window.PayoneerData,w=(e,t)=>{for(const[o,n]of Object.entries(e)){const e=h(o);e instanceof Element&&t.isAvailable(o)&&n.mount(e)}},h=function(e){return document.querySelector(`[${m}=${e}]`)};var f=window.wp.hooks;const g=e=>async({select:t,resolveSelect:o,dispatch:n})=>{const a=await o.getSdk();await a.updateLongId(e),n({type:E.SET_LONG_ID,payload:e})},T=e=>({type:E.SET_SDK_STATE,payload:e});function D(e){return{type:E.SET_ENV,payload:e}}const O=e=>async({select:t,resolveSelect:o,dispatch:n})=>{const a=await o.getSdk();if(console.log(a),!a.isDroppedIn(e)&&"object"==typeof h(e))try{const t={name:e,component:a.dropIn(e,{hidePaymentButton:!0})};console.log("New component",t),n({type:E.ADD_COMPONENT,payload:t}),w({[t.name]:t.component},a)}catch(t){console.error(`Failed to drop in component ${e}. Error details: ${t}`)}};function I(e){return{type:E.REMOVE_COMPONENT,payload:e}}const k=()=>async({select:e,resolveSelect:t,dispatch:o})=>{const n=await t.getSdk(),a=await t.getLongId();await n.updateLongId(a),await o.mountComponents()},v=()=>async({select:e,resolveSelect:t,dispatch:o})=>{f.defaultHooks.doAction("payoneer.webSdk.reboot"),wp.data.dispatch("wc/store/cart").invalidateResolutionForStore(),o.invalidateResolutionForStore(),await o.mountComponents()},P=()=>async({select:e,resolveSelect:t,dispatch:o})=>{const n=await t.getSdk(),a=e.getAvailableDropInComponents();console.log("Mounting components",a),w(a,n)},N=()=>({select:e,dispatch:t})=>{const o=e.getAvailableDropInComponents(),n=e.getActivePaymentMethod(),a=o[S(n)];a?a.pay():console.log("Component not found.")},C=(e,t,o)=>async({select:n,dispatch:a})=>(a.setSdkState(e.state),console.error("WebSDK error:",{sdk:e,component:t,data:o}),["SYSTEM_FAILURE"].includes(o?.interaction?.reason)?(a.setForceHostedFlow(!0),!0):f.defaultHooks.applyFilters("payoneer.webSdk.onSdkError",!1,e,t,o)),L=(e,t,o)=>async({select:n,dispatch:a})=>f.defaultHooks.applyFilters("payoneer.webSdk.onPaymentDeclined",!0,e,t,o),M=(e,t)=>async({select:o,dispatch:n})=>{console.log("onComponentListChange",e,t),t.addedComponents.forEach(e=>{n.addComponent(e)}),t.removedComponents.forEach(e=>{n.removeComponent(e)})},A=(e,t,o)=>async({select:e,dispatch:n})=>{console.log(t,o),n.setIsValid(o.valid)},b=e=>async({dispatch:t})=>{console.log("Setting active payment method",e),t.mountComponents(),t({type:E.SET_ACTIVE_PAYMENT_METHOD,payload:e})};function R(e){return console.log("Setting hosted flow override flag",e),{type:E.SET_FORCE_HOSTED_FLOW,payload:e}}function F(e){return{type:E.SET_IS_VALID,payload:e}}const H=e=>({dispatch:t})=>{t({type:E.SET_ON_PAYMENT_DECLINED_NONCE,payload:e})},V=e=>({dispatch:t})=>{t({type:E.SET_ORDER_ID,payload:e})},x=e=>async({dispatch:t})=>{const o=window.wc_checkout_params.wc_ajax_url.toString().replace("%%endpoint%%","payoneer-checkout-payment-declined"),n=o.includes("?")?"&":"?",a=o+n+"_ajax_nonce="+window.PayoneerData.onPaymentDeclinedNonce;return new Promise((o,n)=>{c().ajax({type:"POST",url:a,xhrFields:{withCredentials:!0},data:e,dataType:"json"}).success(e=>{t.setOnPaymentDeclinedNonce(e.nonce),o(e)}).catch(e=>{console.log(e),n(e)})})};var j=window.wp.apiFetch,K=o.n(j);const{websdkStyles:Y}=PayoneerData,U=()=>async({resolveSelect:e,dispatch:t})=>{const o=await e.getEnv(),n=await e.getSdkVersion(),a=await e.getSdkIntegrity(),r=await e.getLongId(),c=await(s={env:o,sdkVersion:n,sdkIntegrity:a,onBeforeError:async(e,o,n)=>await t.onBeforeError(e,o,n),onPaymentDeclined:async(e,o,n)=>await t.onPaymentDeclined(e,o,n),onComponentListChange:async(e,o)=>await t.onComponentListChange(e,o),onValidationInfo:async(e,o,n)=>await t.onValidationInfo(e,o,n),preload:["cards"],styles:Y},window.Payoneer?.CheckoutWeb?window.Payoneer.CheckoutWeb(s):new Promise((e,t)=>{const o=document.createElement("script");o.src=((e,t)=>{const o=t?`-${t}`:"";return new URL(window.PayoneerData.webSdkUmdUrlTemplate?.replace("<env>",e)?.replace("<version>",o))})(s.env,s.sdkVersion),o.onload=e,o.onerror=t,s.sdkVersion&&s.sdkIntegrity&&(o.integrity=s.sdkIntegrity,o.crossOrigin="anonymous"),document.head.appendChild(o)}).then(()=>window.Payoneer.CheckoutWeb(s)));var s;if("LOADING"===c.state){const e=async()=>await new Promise(e=>{const t=setInterval(()=>{"LOADING"!==c.state&&(e(c.state),clearInterval(t))},1e3)});await e()}await c.updateLongId(r),await t.setForceHostedFlow(!1),await t.setSdkState(c.state),await t({type:E.SET_SDK,payload:c})},G=()=>async({dispatch:e})=>{const t=await K()({path:"/wc/store/v1/cart#skipPreloadingMiddleware",method:"GET",cache:"no-store",parse:!1}),o=(await t.json()).extensions["payoneer-checkout"];console.log("Payoneer Extension Data: ",o),await e({type:E.SET_EXTENSION_DATA,payload:o}),f.defaultHooks.doAction("payoneer.checkout.onReceiveExtensionData",o)},q=()=>async({resolveSelect:e,dispatch:t})=>{const o=await e.getExtensionData();await t({type:E.SET_LONG_ID,payload:o.longId})},W=()=>async({resolveSelect:e,dispatch:t})=>{const o=await e.getExtensionData();await t({type:E.SET_ENV,payload:o.environment})},X=()=>async({resolveSelect:e,dispatch:t})=>{const o=await e.getExtensionData();await t({type:E.SET_SDK_VERSION,payload:o.sdkVersion})},$=()=>async({resolveSelect:e,dispatch:t})=>{const o=await e.getExtensionData();await t({type:E.SET_SDK_INTEGRITY,payload:o.sdkIntegrity})};const B="payoneer-checkout",Q=(0,u.createReduxStore)(B,{reducer:(e=_,t)=>{switch(t.type){case E.SET_EXTENSION_DATA:return{...e,extension:t.payload};case E.SET_LONG_ID:return{...e,longId:t.payload};case E.SET_LIST_URL:return{...e,listUrl:t.payload};case E.SET_ENV:return{...e,env:t.payload};case E.SET_SDK:return{...e,sdk:t.payload};case E.SET_SDK_VERSION:return{...e,sdkVersion:t.payload};case E.SET_SDK_INTEGRITY:return{...e,sdkIntegrity:t.payload};case E.SET_SDK_STATE:return{...e,sdkState:t.payload};case E.SET_ACTIVE_PAYMENT_METHOD:return{...e,activePaymentMethod:t.payload};case E.SET_FORCE_HOSTED_FLOW:return{...e,forceHostedFlow:t.payload};case E.SET_IS_VALID:return{...e,isValid:t.payload};case E.SET_ORDER_ID:return{...e,orderId:t.payload};case E.SET_ON_PAYMENT_DECLINED_NONCE:return{...e,onPaymentDeclinedNonce:t.payload};case E.ADD_COMPONENT:return{...e,availableDropInComponents:{...e.availableDropInComponents,[t.payload.name]:t.payload.component}};case E.REMOVE_COMPONENT:let o={...e.availableDropInComponents};return delete o[t.payload.name],{...e,availableDropInComponents:o};default:return e}},actions:n,selectors:{getExtensionData:e=>e.extension,getLongId:e=>e.longId,getEnv:e=>e.env,getSdkVersion:e=>e.sdkVersion,getSdkIntegrity:e=>e.sdkIntegrity,getSdk:e=>e.sdk,isHostedModeForced:e=>e.forceHostedFlow,getIsValid:e=>"payoneer-checkout"!==e.activePaymentMethod||e.isValid,getActivePaymentMethod:e=>e.activePaymentMethod,getAvailableDropInComponents:e=>e.availableDropInComponents,getOrderId:e=>e.orderId,getOnPaymentDeclinedNonce:e=>e.onPaymentDeclinedNonce},resolvers:a});(0,u.register)(Q);const z="x-payoneer-checkout-force-hosted-flow",Z="x-payoneer-is-payment-checkout",J=()=>{const e={[z]:String((0,u.select)(B).isHostedModeForced()),[Z]:p&&new URLSearchParams(window.location.search).get("key")||""};return f.defaultHooks.applyFilters("payoneer.http.customHeaders",e)};f.defaultHooks.addAction("payoneer.checkout.onReceiveExtensionData","payoneer/setupCustomHttpHeaders",()=>{f.defaultHooks.addFilter("payoneer.http.customHeaders","payoneer/setupCustomHttpHeaders",function(e){return e["x-payoneer-long-id"]=String((0,u.select)(B).getLongId()),e})});var ee=window.wc.wcBlocksData;const te=()=>{const e=function(){const e=null!==(t=document.querySelector('.woocommerce-checkout input[name="payment_method"]:checked').value)&&void 0!==t?t:"";var t;(0,u.dispatch)(B).setActivePaymentMethod(e)};jQuery(document.body).on("payment_method_selected",e),e()};var oe=o(609),ne=o(848);const ae=()=>(0,u.dispatch)(B).initPayoneerComponents(),re=()=>(0,u.dispatch)(B).pay(),ce=()=>(0,u.dispatch)(B).reboot(),se=(0,u.withSelect)((e,t)=>{const o=e(B),{activePaymentMethod:n,eventRegistration:a}=t;return{activePaymentMethod:n,eventRegistration:a,payWithPayoneer:re,initPayoneerComponents:ae,rebootPayoneer:ce,isValid:o.getIsValid()}})(function({payWithPayoneer:e,initPayoneerComponents:t,paymentMethodData:o,rebootPayoneer:n,activePaymentMethod:a,eventRegistration:r,isValid:c}){const{onPaymentSetup:s,onCheckoutSuccess:i,onCheckoutFail:d}=r;(0,oe.useEffect)(()=>{t()},[]),(0,oe.useEffect)(()=>i(({orderId:t})=>{(0,u.dispatch)(B).setOrderId(t),e()}),[]),(0,oe.useEffect)(()=>d(n),[]),(0,oe.useEffect)(()=>s(()=>c?{type:"success"}:{type:"failure",message:"Invalid payment fields"}),[c,s,o]);const l=S(a);return(0,ne.jsx)("div",{className:`payment_method_${a}`,"data-component":l})}),ie=(0,u.select)(B);document.addEventListener("DOMContentLoaded",async()=>{const e=window.fetch;if(window.fetch=async(...t)=>{let[o,n]=t;if(new URL(o,window.location.origin).origin!==window.location.origin)return e(o,n);const a=J();return console.log("Adding custom headers to fetch call",a),n=n&&n.headers?{...n,headers:{...n.headers,...a}}:{...n,headers:a},await e(o,n)},!window.XMLHttpRequest)return;const t=XMLHttpRequest.prototype.open,o=XMLHttpRequest.prototype.send;XMLHttpRequest.prototype.open=function(e,o,...n){this._isSameOrigin=new URL(o,window.location.origin).origin===window.location.origin,t.apply(this,[e,o,...n])},XMLHttpRequest.prototype.send=function(...e){const t=J();if(this._isSameOrigin){console.log("Adding custom headers to XMLHttpRequest call",t);for(const[e,o]of Object.entries(t))this.setRequestHeader(e,o)}o.apply(this,e)}},!1),p()?(console.log("Loading payment checkout integration"),document.addEventListener("DOMContentLoaded",()=>{te(),(0,u.dispatch)(B).setOnPaymentDeclinedNonce(PayoneerData.onPaymentDeclinedNonce);const e=c()("#order_review");f.defaultHooks.addFilter("payoneer.webSdk.onSdkError","payoneer/paymentCheckout",(e,t,o,n)=>{const{payOrderErrorFlag:a}=window.PayoneerData,r=new URL(document.location);return r.searchParams.set(a,!0),window.location.href=r.toString(),e}),wp.hooks.addFilter("payoneer.webSdk.onPaymentDeclined","payoneer/paymentCheckout",async()=>(await wp.data.dispatch(B).releaseOnHoldOrder({longId:(0,u.select)(B).getLongId(),orderKey:new URLSearchParams(window.location.search).get("key")}),window.location.reload(),!1)),e.on("submit",t=>{if(l()&&!(0,u.select)(B).isHostedModeForced()){if(t.preventDefault(),t.stopImmediatePropagation(),!(0,u.select)(B).getIsValid())try{y()}catch(e){console.error(e)}finally{return}var o;(o=e,o.block({message:null,overlayCSS:{background:"#fff",opacity:.6}}),c().ajax({type:"POST",url:window.wc_checkout_params.ajax_url,xhrFields:{withCredentials:!0},dataType:"json",data:{action:"payoneer_order_pay",fields:o.serialize(),params:new URL(document.location).searchParams.toString()}}).always(()=>o.unblock())).then(()=>(0,u.dispatch)(B).pay()).catch(()=>{window.scrollTo(0,0),window.location.reload()})}}),(0,u.dispatch)(B).mountComponents()},!1)):"1"===window?.PayoneerData?.isBlockCheckout?(console.log("Loading classic checkout integration"),(()=>{let e;const t=(0,u.select)(ee.PAYMENT_STORE_KEY),o=()=>{const o=t.getActivePaymentMethod();e!==o&&((0,u.dispatch)(B).setActivePaymentMethod(o),e=o)};(0,u.subscribe)(o,ee.PAYMENT_STORE_KEY),o()})(),Array.isArray(inpsydeGateways)?inpsydeGateways.forEach(e=>{var t;t=e,wp.hooks.addFilter(`${t}_checkout_fields`,t,e=>(e.push(se),e)),wp.hooks.addFilter("payoneer-checkout_payment_method_icons","payoneer-checkout",e=>"payoneer-checkout"===ie.getActivePaymentMethod()?[]:e)}):console.error("window.inpsydeGateways not found"),document.addEventListener("DOMContentLoaded",()=>{wp.hooks.addFilter("payoneer.webSdk.onPaymentDeclined","payoneer/blockCheckout",()=>(wp.data.dispatch(B).releaseOnHoldOrder({longId:(0,u.select)(B).getLongId(),payoneerOrderId:(0,u.select)(B).getOrderId()}),window.location.reload(),!0))},!1)):(console.log("Loading classic checkout integration"),document.addEventListener("DOMContentLoaded",()=>{te(),(0,u.dispatch)(B).setOnPaymentDeclinedNonce(PayoneerData.onPaymentDeclinedNonce);const e=c()("form.checkout");f.defaultHooks.addFilter("payoneer.webSdk.onSdkError","payoneer/shortcodeCheckout",(e,t,o,n)=>(wp.data.dispatch(B).reboot(),c()(document.body).trigger("update_checkout"),e)),wp.hooks.addFilter("payoneer.webSdk.onPaymentDeclined","payoneer/shortcodeCheckout",()=>(wp.data.dispatch(B).releaseOnHoldOrder({longId:(0,u.select)(B).getLongId()}),!1)),c()(document.body).on("updated_checkout",()=>(0,u.dispatch)(B).initPayoneerComponents()),e.on("checkout_place_order",()=>{if((0,u.select)(B).getIsValid())return!0;try{y()}catch(e){console.error(e)}finally{return!1}}),e.on("checkout_place_order_success",(t,o)=>{if(l()&&!(0,u.select)(B).isHostedModeForced())return(0,u.dispatch)(B).pay(),o.redirect="#payoneer-redirect",setTimeout(()=>{e.removeClass("processing").unblock(),c().scroll_to_notices(c()((e=>{const t=".payment_box."+e;return document.querySelector(t)})(d())))},1500),!1})},!1))}();
    22//# sourceMappingURL=payoneer-checkout.js.map
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-embedded-payment/assets/payoneer-checkout.js.map

    r3305047 r3321269  
    1 {"version":3,"file":"payoneer-checkout.js","mappings":"uDASiBA,EAAE,EAAQ,KAASC,EAAEC,OAAOC,IAAI,iBAAgDC,GAA7BF,OAAOC,IAAI,kBAAoBE,OAAOC,UAAUC,gBAAeC,EAAER,EAAES,mDAAmDC,kBAAkBC,EAAE,CAACC,KAAI,EAAGC,KAAI,EAAGC,QAAO,EAAGC,UAAS,GAC+FC,EAAQC,IAAvV,SAAWC,EAAEC,EAAEC,GAAG,IAAIC,EAAEC,EAAE,CAAC,EAAEC,EAAE,KAAKC,EAAE,KAAiF,IAAIH,UAAhF,IAASD,IAAIG,EAAE,GAAGH,QAAG,IAASD,EAAEP,MAAMW,EAAE,GAAGJ,EAAEP,UAAK,IAASO,EAAEN,MAAMW,EAAEL,EAAEN,KAAcM,EAAEf,EAAEqB,KAAKN,EAAEE,KAAKV,EAAEJ,eAAec,KAAKC,EAAED,GAAGF,EAAE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cK,YAAa,cAAetB,UAC1CxI,IAAAA,kBACCA,IrBrDyB/G,KAC9B,MAAM8Q,EAAW,gBAAkB9Q,EACnC,OAAON,SAASC,cAAemR,EAAU,EAIzCC,CAAenR,MqBgDV,GACC,OAEI,CAAK,GACV,IAEJ,G","sources":["webpack://payoneer-embedded-payment/./node_modules/react/cjs/react-jsx-runtime.production.min.js","webpack://payoneer-embedded-payment/external window \"React\"","webpack://payoneer-embedded-payment/./node_modules/react/jsx-runtime.js","webpack://payoneer-embedded-payment/webpack/bootstrap","webpack://payoneer-embedded-payment/webpack/runtime/compat get default export","webpack://payoneer-embedded-payment/webpack/runtime/define property getters","webpack://payoneer-embedded-payment/webpack/runtime/hasOwnProperty shorthand","webpack://payoneer-embedded-payment/webpack/runtime/make namespace object","webpack://payoneer-embedded-payment/external window \"jQuery\"","webpack://payoneer-embedded-payment/./resources/js/src/util/woocommerce.js","webpack://payoneer-embedded-payment/external window [\"wp\",\"data\"]","webpack://payoneer-embedded-payment/./resources/js/src/store/constants.js","webpack://payoneer-embedded-payment/./resources/js/src/store/reducer.js","webpack://payoneer-embedded-payment/./resources/js/src/util/components.js","webpack://payoneer-embedded-payment/external window [\"wp\",\"hooks\"]","webpack://payoneer-embedded-payment/./resources/js/src/store/actions.js","webpack://payoneer-embedded-payment/./resources/js/src/util/sdk/umdLoader.js","webpack://payoneer-embedded-payment/external window [\"wp\",\"apiFetch\"]","webpack://payoneer-embedded-payment/./resources/js/src/store/resolvers.js","webpack://payoneer-embedded-payment/./resources/js/src/store/index.js","webpack://payoneer-embedded-payment/./resources/js/src/store/selectors.js","webpack://payoneer-embedded-payment/./resources/js/src/util/http.js","webpack://payoneer-embedded-payment/external window [\"wc\",\"wcBlocksData\"]","webpack://payoneer-embedded-payment/./resources/js/src/store/storeListeners.js","webpack://payoneer-embedded-payment/./resources/js/src/components/widgetContainer/component.js","webpack://payoneer-embedded-payment/./resources/js/src/components/widgetContainer/provider.js","webpack://payoneer-embedded-payment/./resources/js/src/components/widgetContainer/index.js","webpack://payoneer-embedded-payment/./resources/js/src/util/checkout/blockCheckout.js","webpack://payoneer-embedded-payment/./resources/js/payoneer-checkout.js","webpack://payoneer-embedded-payment/./resources/js/src/util/checkout/paymentCheckout.js","webpack://payoneer-embedded-payment/./resources/js/src/util/checkout/classicCheckout.js"],"sourcesContent":["/**\n * @license React\n * react-jsx-runtime.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var f=require(\"react\"),k=Symbol.for(\"react.element\"),l=Symbol.for(\"react.fragment\"),m=Object.prototype.hasOwnProperty,n=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p={key:!0,ref:!0,__self:!0,__source:!0};\nfunction q(c,a,g){var b,d={},e=null,h=null;void 0!==g&&(e=\"\"+g);void 0!==a.key&&(e=\"\"+a.key);void 0!==a.ref&&(h=a.ref);for(b in a)m.call(a,b)&&!p.hasOwnProperty(b)&&(d[b]=a[b]);if(c&&c.defaultProps)for(b in a=c.defaultProps,a)void 0===d[b]&&(d[b]=a[b]);return{$$typeof:k,type:c,key:e,ref:h,props:d,_owner:n.current}}exports.Fragment=l;exports.jsx=q;exports.jsxs=q;\n","module.exports = window[\"React\"];","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n  module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n  module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"jQuery\"];","import $ from 'jquery';\nconst {\n\tpaymentFieldsComponentAttribute\n} = window.PayoneerData;\n\nexport const paymentMethodName = () => {\n\treturn document.querySelector( '.woocommerce-checkout input[name=\"payment_method\"]:checked' ).value ?? '';\n}\n\nexport const selectedPaymentGateway = () => {\n\treturn document.querySelector(\n\t\t'.woocommerce-checkout input[name=\"payment_method\"]:checked'\n\t)\n};\n\nexport const selectedPaymentGatewayId = () => {\n\treturn selectedPaymentGateway()?.id;\n};\n\nexport const getComponentNameFromPaymentBox = function ( paymentBox ) {\n\treturn paymentBox\n\t\t?.querySelector( `[${ paymentFieldsComponentAttribute }]` )\n\t\t?.getAttribute( paymentFieldsComponentAttribute );\n};\n\nexport const isPayoneerGateway = ( gatewayId ) => {\n\treturn /^payment_method_payoneer-(checkout|afterpay)/i.test( gatewayId );\n};\n\nexport const isPayoneerGatewaySelected = () =>\n\tisPayoneerGateway( selectedPaymentGatewayId() );\n\nexport const isPayForOrder = () => {\n\treturn window.PayoneerData.isPayForOrder === '1';\n};\n\nexport const getPaymentBox = ( gatewayId ) => {\n\tconst selector = '.payment_box.' + gatewayId;\n\treturn document.querySelector( selector );\n};\n\nexport const getSelectedPaymentBox = () =>\n\tgetPaymentBox( selectedPaymentGatewayId() );\n\nconst hostedOverrideFlagInput = () => {\n\tconst { hostedFlowOverrideFlag } = window.PayoneerData;\n\treturn document.querySelector(\n\t\t`input[name=\"${ hostedFlowOverrideFlag }\"]`\n\t);\n};\n\nexport const submitOrderPayViaAjax = ( $form ) => {\n\t//Blocks the UI in the same way Woocommerce does (source: https://github.com/woocommerce/woocommerce/blob/6.0.1/plugins/woocommerce/assets/js/frontend/checkout.js#L454-L466)\n\t$form.block( {\n\t\tmessage: null,\n\t\toverlayCSS: {\n\t\t\tbackground: '#fff',\n\t\t\topacity: 0.6,\n\t\t},\n\t} );\n\n\treturn $.ajax( {\n\t\ttype: 'POST',\n\t\turl: window.wc_checkout_params.ajax_url,\n\t\txhrFields: {\n\t\t\t// This is important. We need the session cookie to access the LIST in the back-end\n\t\t\twithCredentials: true,\n\t\t},\n\t\tdataType: 'json',\n\t\tdata: {\n\t\t\taction: 'payoneer_order_pay',\n\t\t\tfields: $form.serialize(),\n\t\t\tparams: new URL( document.location ).searchParams.toString(),\n\t\t},\n\t} ).always( () => $form.unblock() );\n};\n\nexport const isBlockCheckout = () =>\n\twindow?.PayoneerData?.isBlockCheckout === '1';\n\nexport const focusOnSelectedGateway = () => {\n\tselectedPaymentGateway()?.focus();\n}\n","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"data\"];","export const ACTIONS = {\n\tSET_EXTENSION_DATA: 'SET_EXTENSION_DATA',\n\tSET_LONG_ID: 'SET_LONG_ID',\n\tSET_LIST_URL: 'SET_LIST_URL',\n\tSET_ENV: 'SET_ENV',\n\tSET_SDK: 'SET_SDK',\n\tSET_SDK_VERSION: 'SET_SDK_VERSION',\n\tSET_SDK_INTEGRITY: 'SET_SDK_INTEGRITY',\n\tSET_SDK_STATE: 'SET_SDK_STATE',\n\tADD_COMPONENT: 'ADD_COMPONENT',\n\tREMOVE_COMPONENT: 'REMOVE_COMPONENT',\n\tMOUNT_COMPONENTS: 'MOUNT_COMPONENTS',\n\tPAY: 'PAY',\n\tSET_ACTIVE_PAYMENT_METHOD: 'SET_ACTIVE_PAYMENT_METHOD',\n\tSET_FORCE_HOSTED_FLOW: 'SET_FORCE_HOSTED_FLOW',\n\tSET_IS_VALID: 'SET_IS_VALID',\n\tSET_ORDER_ID: 'SET_ORDER_ID',\n\tSET_ON_PAYMENT_DECLINED_NONCE: 'SET_ON_PAYMENT_DECLINED_NONCE',\n};\n","import { ACTIONS } from './constants';\n\nconst initialState = {\n\tactivePaymentMethod: '',\n\tlongId: null,\n\tenv: null,\n\tsdkState: 'UNINITIALIZED',\n\tforceHostedFlow: true,\n\tisValid: false,\n\tavailableDropInComponents: []\n};\n\nconst reducer = (state = initialState, action) => {\n\tswitch (action.type) {\n\t\tcase ACTIONS.SET_EXTENSION_DATA:\n\t\t\treturn { ...state, extension: action.payload };\n\t\tcase ACTIONS.SET_LONG_ID:\n\t\t\treturn { ...state, longId: action.payload };\n\t\tcase ACTIONS.SET_LIST_URL:\n\t\t\treturn { ...state, listUrl: action.payload };\n\t\tcase ACTIONS.SET_ENV:\n\t\t\treturn { ...state, env: action.payload };\n\t\tcase ACTIONS.SET_SDK:\n\t\t\treturn { ...state, sdk: action.payload };\n\t\tcase ACTIONS.SET_SDK_VERSION:\n\t\t\treturn { ...state, sdkVersion: action.payload };\n\t\tcase ACTIONS.SET_SDK_INTEGRITY:\n\t\t\treturn { ...state, sdkIntegrity: action.payload };\n\t\tcase ACTIONS.SET_SDK_STATE:\n\t\t\treturn { ...state, sdkState: action.payload };\n\t\tcase ACTIONS.SET_ACTIVE_PAYMENT_METHOD:\n\t\t\treturn { ...state, activePaymentMethod: action.payload };\n\t\tcase ACTIONS.SET_FORCE_HOSTED_FLOW:\n\t\t\treturn { ...state, forceHostedFlow: action.payload };\n\t\tcase ACTIONS.SET_IS_VALID:\n\t\t\treturn { ...state, isValid: action.payload };\n\t\tcase ACTIONS.SET_ORDER_ID:\n\t\t\treturn { ...state, orderId: action.payload };\n\t\tcase ACTIONS.SET_ON_PAYMENT_DECLINED_NONCE:\n\t\t\treturn { ...state, onPaymentDeclinedNonce: action.payload };\n\t\tcase ACTIONS.ADD_COMPONENT:\n\t\t\treturn {\n\t\t\t\t...state,\n\t\t\t\tavailableDropInComponents: {\n\t\t\t\t\t...state.availableDropInComponents,\n\t\t\t\t\t[action.payload.name]: action.payload.component\n\t\t\t\t}\n\t\t\t};\n\t\tcase ACTIONS.REMOVE_COMPONENT:\n\t\t\tlet availableDropInComponents = { ...state.availableDropInComponents };\n\t\t\tdelete availableDropInComponents[action.payload.name];\n\t\t\treturn { ...state, availableDropInComponents };\n\t\tdefault:\n\t\t\treturn state;\n\t}\n};\n\nexport default reducer;\n","import {\n\tgetPaymentBox,\n\tgetComponentNameFromPaymentBox,\n\tsetHostedOverride\n} from './woocommerce';\n\nexport const getComponentNameByGatewayId = ( gatewayId ) => {\n\tconst gatewayIdToComponentName = {\n\t\t'payoneer-checkout': 'cards',\n\t\t'payoneer-afterpay': 'afterpay',\n\t};\n\n\treturn gatewayIdToComponentName[ gatewayId ];\n}\n\nconst { paymentFieldsComponentAttribute } = window.PayoneerData;\n\nexport const mountComponents = ( components, sdk ) => {\n\tfor ( const [ componentName, component ] of Object.entries( components ) ) {\n\t\tconst container = findComponentContainer( componentName );\n\t\tif (\n\t\t\tcontainer instanceof Element &&\n\t\t\tsdk.isAvailable( componentName )\n\t\t) {\n\t\t\tcomponent.mount( container );\n\t\t}\n\t}\n};\n\nexport const findComponentContainer = function ( componentName ) {\n\treturn document.querySelector(\n\t\t`[${paymentFieldsComponentAttribute}=${componentName}]`\n\t);\n};\n","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"hooks\"];","import {\n\tmountComponents as doMountComponents,\n\tgetComponentNameByGatewayId,\n\tfindComponentContainer\n} from '../util/components';\nimport { ACTIONS } from './constants';\nimport { defaultHooks } from \"@wordpress/hooks\";\nimport $ from 'jquery';\n\nexport const setLongId = ( longId ) => async ( { select, resolveSelect, dispatch } ) => {\n\tconst sdk = await resolveSelect.getSdk()\n\tawait sdk.updateLongId( longId );\n\tdispatch( { type: ACTIONS.SET_LONG_ID, payload: longId } );\n}\n\nexport const setSdkState = ( sdkState ) => {\n\treturn { type: ACTIONS.SET_SDK_STATE, payload: sdkState };\n};\n\nexport function setEnv( env ) {\n\treturn { type: ACTIONS.SET_ENV, payload: env };\n}\n\nexport const addComponent = ( componentName ) => async ( { select, resolveSelect, dispatch } ) => {\n\tconst sdk = await resolveSelect.getSdk()\n\tconsole.log( sdk )\n\tif ( !sdk.isDroppedIn( componentName ) && typeof findComponentContainer( componentName ) === 'object' ) {\n\t\ttry {\n\t\t\tconst payload = {\n\t\t\t\tname: componentName,\n\t\t\t\tcomponent: sdk.dropIn( componentName, {\n\t\t\t\t\thidePaymentButton: true,\n\t\t\t\t} )\n\t\t\t};\n\t\t\tconsole.log( 'New component', payload );\n\t\t\tdispatch( { type: ACTIONS.ADD_COMPONENT, payload } );\n\t\t\tdoMountComponents( { [ payload.name ]: payload.component }, sdk );\n\t\t} catch ( e ) {\n\t\t\tconsole.error( `Failed to drop in component ${componentName}. Error details: ${e}` );\n\t\t}\n\t}\n}\n\nexport function removeComponent( componentName ) {\n\treturn { type: ACTIONS.REMOVE_COMPONENT, payload: componentName };\n}\n\n/**\n * When a React component is displayed for the first time, the SDK needs to mount its dropIn.\n * So they call this function in a useEffect callback.\n * However:\n * If the SDK has been bootstrapped already, and a new method becomes available after\n * checkout field changes we need to instruct the SDK to refetch the list of dropIn components.\n * This is why we call sdk.updateLongId()\n * After that, the onComponentListChange handler should take care of mounting automatically\n *\n * @returns {(function({select: *, resolveSelect: *, dispatch: *}): Promise<void>)|*}\n */\nexport const initPayoneerComponents = () => async ( { select, resolveSelect, dispatch } ) => {\n\tconst sdk = await resolveSelect.getSdk()\n\tconst longId = await resolveSelect.getLongId()\n\tawait sdk.updateLongId( longId );\n\tawait dispatch.mountComponents()\n}\n\nexport const reboot = () => async ( { select, resolveSelect, dispatch } ) => {\n\tdefaultHooks.doAction( 'payoneer.webSdk.reboot' )\n\twp.data.dispatch( 'wc/store/cart' ).invalidateResolutionForStore();\n\tdispatch.invalidateResolutionForStore()\n\tawait dispatch.mountComponents()\n}\n\nexport const mountComponents = () => async ( { select, resolveSelect, dispatch } ) => {\n\tconst sdk = await resolveSelect.getSdk()\n\tconst availableComponents = select.getAvailableDropInComponents();\n\tconsole.log( 'Mounting components', availableComponents );\n\tdoMountComponents( availableComponents, sdk );\n};\n\nexport const pay = () => ( { select, dispatch } ) => {\n\tconst availableComponents = select.getAvailableDropInComponents();\n\tconst activePaymentMethod = select.getActivePaymentMethod();\n\tconst componentName = getComponentNameByGatewayId( activePaymentMethod );\n\tconst component = availableComponents[ componentName ];\n\tif ( !component ) {\n\t\tconsole.log( 'Component not found.' );\n\t\treturn;\n\t}\n\tcomponent.pay();\n};\n\nexport const onBeforeError = ( sdk, component, data ) => async ( { select, dispatch } ) => {\n\tdispatch.setSdkState( sdk.state );\n\tconsole.error( \"WebSDK error:\", { sdk, component, data } );\n\t/**\n\t * For SYSTEM_FAILURE, we assume there is nothing we can do to recover.\n\t * Use hosted mode fallback and let the customer proceed\n\t */\n\tif ( [ \"SYSTEM_FAILURE\" ].includes( data?.interaction?.reason ) ) {\n\t\tdispatch.setForceHostedFlow( true );\n\t\treturn true;\n\t}\n\t/**\n\t * Let the outside world attempt to handle the error.\n\t * The different checkout types can reboot the payment attempt from there.\n\t */\n\treturn defaultHooks.applyFilters( 'payoneer.webSdk.onSdkError', false, sdk, component, data );\n}\n\nexport const onPaymentDeclined = ( sdk, component, data ) => async ( { select, dispatch } ) => {\n\treturn defaultHooks.applyFilters( 'payoneer.webSdk.onPaymentDeclined', true, sdk, component, data )\n}\n\nexport const onComponentListChange = ( sdk, changeInfo ) => async ( { select, dispatch } ) => {\n\tconsole.log( 'onComponentListChange', sdk, changeInfo );\n\tchangeInfo.addedComponents.forEach( ( name ) => {\n\t\tdispatch.addComponent( name );\n\t} );\n\tchangeInfo.removedComponents.forEach( ( name ) => {\n\t\tdispatch.removeComponent( name );\n\t} );\n}\nexport const onValidationInfo = ( sdk, componentName, data ) => async ( { select, dispatch } ) => {\n\tconsole.log(componentName,data)\n\tdispatch.setIsValid( data.valid )\n}\n\nexport const setActivePaymentMethod = ( method ) => async ( { dispatch } ) => {\n\tconsole.log( 'Setting active payment method', method );\n\tdispatch.mountComponents()\n\tdispatch( { type: ACTIONS.SET_ACTIVE_PAYMENT_METHOD, payload: method } );\n}\n\nexport function setForceHostedFlow( state ) {\n\tconsole.log( 'Setting hosted flow override flag', state );\n\treturn { type: ACTIONS.SET_FORCE_HOSTED_FLOW, payload: state };\n}\n\nexport function setIsValid( flag ) {\n\treturn { type: ACTIONS.SET_IS_VALID, payload: flag };\n}\n\nexport const setOnPaymentDeclinedNonce = ( nonce ) => ( {dispatch} ) => {\n\tdispatch( { type: ACTIONS.SET_ON_PAYMENT_DECLINED_NONCE, payload: nonce} );\n}\n\nexport const setOrderId = ( orderId ) => ( {dispatch} ) => {\n\tdispatch( { type: ACTIONS.SET_ORDER_ID, payload: orderId } );\n}\n\nexport const releaseOnHoldOrder = (requestData) => async ( { dispatch } ) => {\n\tconst targetUrlBase = window.wc_checkout_params.wc_ajax_url.\n\ttoString().\n\treplace( '%%endpoint%%', 'payoneer-checkout-payment-declined' );\n\tconst separator = targetUrlBase.includes('?') ? '&' : '?';\n\tconst targetUrl = targetUrlBase +\n\t\tseparator +\n\t\t'_ajax_nonce=' +\n\t\twindow.PayoneerData.onPaymentDeclinedNonce\n\n\treturn new Promise( ( resolve, reject ) => {\n\t\t$.ajax( {\n\t\t\ttype: 'POST',\n\t\t\turl: targetUrl,\n\t\t\txhrFields: {\n\t\t\t\t// This is important. We need the session cookie to access the LIST in the back-end\n\t\t\t\twithCredentials: true,\n\t\t\t},\n\t\t\tdata: requestData,\n\t\t\tdataType: 'json',\n\t\t} ).success( ( data ) => {\n\t\t\t//New nonce for the next request.\n\t\t\tdispatch.setOnPaymentDeclinedNonce( data.nonce );\n\t\t\tresolve( data );\n\t\t} ).catch( ( e ) => {\n\t\t\tconsole.log( e );\n\t\t\treject( e )\n\t\t} );\n\t} );\n}\n","/*\n * Since the WebSDK is not yet available on npm, we asynchronously\n * load the UMD version from the appropriate env whenever the SDK is initialized\n * for the first time.\n */\n\nconst formatUmdUrl = ( env, sdkVersion ) => {\n\t/**\n\t * When the configuration does not provide a pinned version we can omit the script version to\n\t * load the latest version of the SDK.\n\t *\n\t * @type {string}\n\t */\n\tconst scriptVersion = sdkVersion ? `-${sdkVersion}` : '';\n\n\treturn new URL(\n\t\twindow.PayoneerData.webSdkUmdUrlTemplate\n\t\t\t?.replace( '<env>', env )\n\t\t\t?.replace( '<version>', scriptVersion )\n\t);\n};\n\nconst sdkLoader = ( config ) => {\n\tif ( window.Payoneer?.CheckoutWeb ) {\n\t\treturn window.Payoneer.CheckoutWeb( config );\n\t}\n\n\treturn new Promise( ( resolve, reject ) => {\n\t\tconst script = document.createElement( 'script' );\n\t\tscript.src = formatUmdUrl( config.env, config.sdkVersion );\n\t\tscript.onload = resolve;\n\t\tscript.onerror = reject;\n\n\t\t/**\n\t\t * Add Subresource Integrity (SRI) validation when a specific SDK version is requested.\n\t\t * This enhances security by ensuring the loaded script matches its expected content,\n\t\t * which is a requirement for PCI compliance.\n\t\t */\n\t\tif ( config.sdkVersion && config.sdkIntegrity ) {\n\t\t\tscript.integrity = config.sdkIntegrity;\n\n\t\t\t// Add crossorigin attribute when using integrity checks.\n\t\t\t// This is required for SRI to work properly with CORS.\n\t\t\tscript.crossOrigin = 'anonymous';\n\t\t}\n\t\tdocument.head.appendChild( script );\n\t} ).then( () => {\n\t\treturn window.Payoneer.CheckoutWeb( config );\n\t} );\n};\n\nexport default sdkLoader;\n","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"apiFetch\"];","import { ACTIONS } from \"./constants\";\nimport initializeSdk from \"../util/sdk/umdLoader\";\nimport apiFetch from '@wordpress/api-fetch';\nimport { defaultHooks } from \"@wordpress/hooks\";\n\nconst {\n\twebsdkStyles: styles\n} = PayoneerData;\n\nexport const getSdk = () => async ( { resolveSelect, dispatch } ) => {\n\tconst env = await resolveSelect.getEnv();\n\tconst sdkVersion = await resolveSelect.getSdkVersion();\n\tconst sdkIntegrity = await resolveSelect.getSdkIntegrity();\n\tconst longId = await resolveSelect.getLongId();\n\tconst onBeforeError = async ( sdk, component, data ) => await dispatch.onBeforeError( sdk, component, data );\n\tconst onPaymentDeclined = async ( sdk, component, data ) => await dispatch.onPaymentDeclined( sdk, component, data );\n\tconst onComponentListChange = async ( sdk, changeInfo ) => await dispatch.onComponentListChange( sdk, changeInfo );\n\tconst onValidationInfo = async ( sdk, componentName, data ) => await dispatch.onValidationInfo( sdk, componentName, data );\n\n\tconst sdk = await initializeSdk( {\n\t\tenv,\n\t\tsdkVersion,\n\t\tsdkIntegrity,\n\t\tonBeforeError,\n\t\tonPaymentDeclined,\n\t\tonComponentListChange,\n\t\tonValidationInfo,\n\t\tpreload: [ 'cards' ],\n\t\tstyles\n\t} );\n\n\tif ( sdk.state === 'LOADING' ) {\n\t\tconst nonLoadingState = async () => {\n\t\t\treturn await new Promise( resolve => {\n\t\t\t\tconst interval = setInterval( () => {\n\t\t\t\t\tif ( sdk.state !== 'LOADING' ) {\n\t\t\t\t\t\tresolve( sdk.state );\n\t\t\t\t\t\tclearInterval( interval );\n\t\t\t\t\t}\n\t\t\t\t}, 1000 );\n\t\t\t} );\n\t\t};\n\t\tawait nonLoadingState();\n\t}\n\tawait sdk.updateLongId( longId );\n\tawait dispatch.setForceHostedFlow( false );\n\tawait dispatch.setSdkState( sdk.state );\n\tawait dispatch( { type: ACTIONS.SET_SDK, payload: sdk } );\n}\n/**\n * Perform a Store API call to the cart endpoint where we provide LIST longId and environment\n */\nexport const getExtensionData = () => async ( { dispatch } ) => {\n\n\tconst response = await apiFetch( {\n\t\t/**\n\t\t * /wc/store/v1/cart\n\t\t * is pre-warmed in PHP, so the first API call will always get data produced during\n\t\t * the initial page load.\n\t\t * Here we MUST receive the results of an actual API call.\n\t\t * So we use a custom URL hash to prevent this from happening.\n\t\t */\n\t\tpath: '/wc/store/v1/cart#skipPreloadingMiddleware',\n\t\tmethod: 'GET',\n\t\tcache: 'no-store',\n\t\tparse: false,\n\t} );\n\tconst json = await response.json();\n\tconst payoneerExtensionData = json.extensions[ 'payoneer-checkout' ];\n\tconsole.log('Payoneer Extension Data: ', payoneerExtensionData);\n\tawait dispatch( { type: ACTIONS.SET_EXTENSION_DATA, payload: payoneerExtensionData } );\n\tdefaultHooks.doAction( 'payoneer.checkout.onReceiveExtensionData', payoneerExtensionData )\n}\nexport const getLongId = () => async ( { resolveSelect,dispatch } ) => {\n\tconst extensionData = await resolveSelect.getExtensionData();\n\tawait dispatch( { type: ACTIONS.SET_LONG_ID, payload: extensionData.longId } );\n}\n\nexport const getEnv = () => async ( { resolveSelect,dispatch } ) => {\n\tconst extensionData = await resolveSelect.getExtensionData();\n\tawait dispatch( { type: ACTIONS.SET_ENV, payload: extensionData.environment } );\n}\n\nexport const getSdkVersion = () => async ( { resolveSelect,dispatch } ) => {\n\tconst extensionData = await resolveSelect.getExtensionData();\n\tawait dispatch( { type: ACTIONS.SET_SDK_VERSION, payload: extensionData.sdkVersion } );\n}\n\nexport const getSdkIntegrity = () => async ( { resolveSelect,dispatch } ) => {\n\tconst extensionData = await resolveSelect.getExtensionData();\n\tawait dispatch( { type: ACTIONS.SET_SDK_INTEGRITY, payload: extensionData.sdkIntegrity } );\n}\n","import { createReduxStore, register } from '@wordpress/data';\nimport reducer from './reducer';\nimport * as actions from './actions';\nimport * as resolvers from './resolvers';\nimport selectors from './selectors';\n\nexport const PAYONEER_STORE_KEY = 'payoneer-checkout';\n\nexport const payoneerStore = createReduxStore(PAYONEER_STORE_KEY, {\n\treducer,\n\tactions,\n\tselectors,\n\tresolvers\n});\n\nregister(payoneerStore);\n\n","\nconst selectors = {\n\t/**\n\t * This is technically only needed temporarily to lazy-fetch longId and env\n\t * in a resolver. Maybe there are better ways to deal with this?\n\t */\n\tgetExtensionData: (state) => state.extension,\n\tgetLongId: (state) => state.longId,\n\tgetEnv: (state) => state.env,\n\tgetSdkVersion: (state) => state.sdkVersion,\n\tgetSdkIntegrity: (state) => state.sdkIntegrity,\n\tgetSdk: (state) => state.sdk,\n\tisHostedModeForced: (state) => state.forceHostedFlow,\n\t/**\n\t * Validity only makes sense for Cards payment method\n\t * https://checkoutdocs.payoneer.com/docs/payment-button#listening-for-validation-events\n\t */\n\tgetIsValid: (state) =>\n\t\tstate.activePaymentMethod !== 'payoneer-checkout' ||\n\t\tstate.isValid,\n\tgetActivePaymentMethod: (state) => state.activePaymentMethod,\n\tgetAvailableDropInComponents: (state) => state.availableDropInComponents,\n\tgetOrderId: (state) => state.orderId,\n\tgetOnPaymentDeclinedNonce: (state) => state.onPaymentDeclinedNonce,\n};\n\nexport default selectors;\n","import { PAYONEER_STORE_KEY } from \"../store/index\";\nimport { select } from '@wordpress/data';\nimport { isPayForOrder } from \"./woocommerce\";\nimport { defaultHooks } from \"@wordpress/hooks\";\n\nconst FORCE_HOSTED_MODE_HEADER = 'x-payoneer-checkout-force-hosted-flow'\nconst LIST_LONG_ID = 'x-payoneer-long-id'\nconst IS_PAYMENT_CHECKOUT = 'x-payoneer-is-payment-checkout'\n\nconst paymentCheckoutHeaderValue = () => {\n\tif ( !isPayForOrder ) {\n\t\treturn '' // to avoid receiving random variables from non-payment pages\n\t}\n\tconst urlParams = new URLSearchParams( window.location.search );\n\treturn urlParams.get( 'key' ) || '';\n};\n\nconst getCustomHeaders = () => {\n\tconst customHeaders = {\n\t\t[ FORCE_HOSTED_MODE_HEADER ]: String( select( PAYONEER_STORE_KEY ).isHostedModeForced() ),\n\t\t[ IS_PAYMENT_CHECKOUT ]: paymentCheckoutHeaderValue()\n\t};\n\treturn defaultHooks.applyFilters( 'payoneer.http.customHeaders', customHeaders );\n};\n\n/**\n * Since we need the getLongId resolver to have run once, we defer adding the header\n */\ndefaultHooks.addAction(\n\t'payoneer.checkout.onReceiveExtensionData',\n\t'payoneer/setupCustomHttpHeaders',\n\t() => {\n\t\tdefaultHooks.addFilter(\n\t\t\t'payoneer.http.customHeaders',\n\t\t\t'payoneer/setupCustomHttpHeaders',\n\t\t\tfunction ( headers ) {\n\t\t\t\theaders[ LIST_LONG_ID ] = String( select( PAYONEER_STORE_KEY ).getLongId() )\n\t\t\t\treturn headers;\n\t\t\t}\n\t\t)\n\t} );\n\n/**\n * We decorate the global fetch function so that we can pass custom headers for outgoing requests.\n * This is used to control the hosted mode fallback in the back-end and for validating\n * that the frontend LIST longId matches the one used by the backend\n */\nexport const setupCustomHttpHeaders = async () => {\n\n\tconst originalFetch = window.fetch;\n\n\twindow.fetch = async ( ...args ) => {\n\t\tlet [ url, options ] = args;\n\t\t// Only process requests going out to the same origin\n\t\tif ( new URL( url, window.location.origin ).origin !== window.location.origin ) {\n\t\t\treturn originalFetch( url, options );\n\t\t}\n\t\tconst customHeaders = getCustomHeaders();\n\t\tconsole.log( 'Adding custom headers to fetch call', customHeaders );\n\t\t// Clone the original options to avoid mutating it\n\t\tif ( options && options.headers ) {\n\t\t\toptions = { ...options, headers: { ...options.headers, ...customHeaders } };\n\t\t} else {\n\t\t\toptions = { ...options, headers: customHeaders };\n\t\t}\n\n\t\treturn await originalFetch( url, options );\n\t};\n\n\tif ( !window.XMLHttpRequest ) {\n\t\treturn;\n\t}\n\n\tconst originalOpen = XMLHttpRequest.prototype.open;\n\tconst originalSend = XMLHttpRequest.prototype.send;\n\n\tXMLHttpRequest.prototype.open = function ( method, url, ...rest ) {\n\t\tthis._isSameOrigin = new URL( url, window.location.origin ).origin === window.location.origin;\n\t\toriginalOpen.apply( this, [ method, url, ...rest ] );\n\t};\n\n\tXMLHttpRequest.prototype.send = function ( ...args ) {\n\t\tconst customHeaders = getCustomHeaders();\n\n\t\tif ( this._isSameOrigin ) {\n\t\t\tconsole.log( 'Adding custom headers to XMLHttpRequest call', customHeaders );\n\t\t\tfor ( const [ header, value ] of Object.entries( customHeaders ) ) {\n\t\t\t\tthis.setRequestHeader( header, value );\n\t\t\t}\n\t\t}\n\t\toriginalSend.apply( this, args );\n\t};\n}\n","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wc\"][\"wcBlocksData\"];","import { dispatch } from '@wordpress/data';\nimport { PAYMENT_STORE_KEY } from '@woocommerce/block-data';\nimport { PAYONEER_STORE_KEY } from \"./index\";\nimport { select, subscribe } from '@wordpress/data';\nimport { paymentMethodName } from \"../util/woocommerce\";\n\nexport const setUpBlockCheckoutListeners = () => {\n\n\tlet currentPaymentMethod;\n\n\tconst wcPaymentStore = select( PAYMENT_STORE_KEY );\n\tconst paymentStoreCallback = () => {\n\t\tconst paymentMethod = wcPaymentStore.getActivePaymentMethod();\n\t\tif ( currentPaymentMethod !== paymentMethod ) {\n\t\t\tdispatch( PAYONEER_STORE_KEY ).setActivePaymentMethod( paymentMethod );\n\t\t\tcurrentPaymentMethod = paymentMethod;\n\t\t}\n\t}\n\tconst unsubscribePaymentStore = subscribe( paymentStoreCallback, PAYMENT_STORE_KEY );\n\tpaymentStoreCallback()\n\n\treturn { unsubscribePaymentStore };\n}\n\nexport const setupClassicCheckoutListeners = () => {\n\tconst paymentMethodCallback = function () {\n\t\tconst methodName = paymentMethodName()\n\t\tdispatch( PAYONEER_STORE_KEY ).setActivePaymentMethod( methodName );\n\t}\n\tjQuery( document.body ).on( 'payment_method_selected', paymentMethodCallback );\n\tpaymentMethodCallback()\n}\n\n\n","import { useEffect } from 'react';\nimport { getComponentNameByGatewayId } from \"../../util/components\";\nimport { dispatch } from '@wordpress/data'\nimport { PAYONEER_STORE_KEY } from \"../../store/index\";\n/**\n * @see https://developer.woocommerce.com/2022/10/06/how-the-checkout-block-processes-an-order/\n * @see https://developer.woocommerce.com/docs/cart-and-checkout-payment-method-integration-for-the-checkout-block/#3-props-fed-to-payment-method-nodes\n */\nexport const Component = function (\n\t{\n\t\tpayWithPayoneer,\n\t\tinitPayoneerComponents,\n\t\tpaymentMethodData,\n\t\trebootPayoneer,\n\t\tactivePaymentMethod,\n\t\teventRegistration,\n\t\tisValid\n\t}\n) {\n\n\tconst { onPaymentSetup, onCheckoutSuccess, onCheckoutFail } = eventRegistration;\n\t/**\n\t * Ping the SDK when we see the light of day\n\t */\n\tuseEffect( () => {\n\t\tinitPayoneerComponents()\n\t}, [] )\n\n\tuseEffect( () => {\n\t\treturn onCheckoutSuccess( ({orderId}) => {\n\t\t\tdispatch(PAYONEER_STORE_KEY).setOrderId(orderId);\n\t\t\tpayWithPayoneer();\n\t\t} );\n\t}, [] );\n\n\tuseEffect( () => {\n\t\treturn onCheckoutFail( rebootPayoneer );\n\t}, [] );\n\t/**\n\t * Enhance the payment data validation step.\n\t * We need to validate that the LIST used in block checkout submit\n\t * matches the one we will use for finalizing the transaction in the backend.\n\t * Therefore, we pass additional metadata in this listener\n\t */\n\tuseEffect( () => {\n\t\treturn onPaymentSetup( () => {\n\t\t\treturn isValid\n\t\t\t\t?\n\t\t\t\t{\n\t\t\t\t\ttype: 'success',\n\t\t\t\t}\n\t\t\t\t:\n\t\t\t\t{\n\t\t\t\t\ttype: 'failure',\n\t\t\t\t\tmessage: 'Invalid payment fields',\n\t\t\t\t}\n\t\t} );\n\t}, [ isValid, onPaymentSetup, paymentMethodData ] );\n\n\tconst componentName = getComponentNameByGatewayId( activePaymentMethod );\n\n\treturn <div\n\t\tclassName={`payment_method_${activePaymentMethod}`}\n\t\tdata-component={componentName}\n\t></div>;\n}\n","import { PAYONEER_STORE_KEY } from \"../../store\";\nimport { dispatch, withSelect } from '@wordpress/data';\n\nconst initPayoneerComponents = () => dispatch( PAYONEER_STORE_KEY ).initPayoneerComponents();\nconst payWithPayoneer = () => dispatch( PAYONEER_STORE_KEY ).pay();\nconst rebootPayoneer = () => dispatch( PAYONEER_STORE_KEY ).reboot();\n\n/**\n * Higher-Order Component that maps the inner component's props to our payoneer store\n */\nexport const provider = withSelect(\n\t( select, ownProps ) => {\n\t\tconst payoneer = select( PAYONEER_STORE_KEY )\n\t\tconst {\n\t\t\tactivePaymentMethod,\n\t\t\teventRegistration\n\t\t} = ownProps\n\t\treturn {\n\t\t\tactivePaymentMethod,\n\t\t\teventRegistration,\n\t\t\tpayWithPayoneer,\n\t\t\tinitPayoneerComponents,\n\t\t\trebootPayoneer,\n\t\t\tisValid: payoneer.getIsValid()\n\t\t}\n\t}\n)\n","import {Component} from './component'\nimport {provider} from './provider'\n\nexport const WidgetContainer = provider(Component)\n","import { setUpBlockCheckoutListeners } from \"../../store/storeListeners\";\nimport {WidgetContainer} from '../../components/widgetContainer';\nimport {select, dispatch} from '@wordpress/data';\nimport { PAYONEER_STORE_KEY } from \"../../store/index\";\nimport $ from 'jquery';\nimport { getLongId } from \"../../store/resolvers\";\n\nconst payoneerStore = select( PAYONEER_STORE_KEY );\n\nconst setUpGatewayContainers = function () {\n\tif ( !Array.isArray( inpsydeGateways ) ) {\n\t\tconsole.error('window.inpsydeGateways not found')\n\t\treturn;\n\t}\n\n\tinpsydeGateways.forEach( ( gatewayName ) => {\n\t\taddWidgetContainer( gatewayName );\n\t} );\n};\n\nconst addWidgetContainer = function ( gatewayId ) {\n\twp.hooks.addFilter( `${gatewayId}_checkout_fields`, gatewayId, ( components ) => {\n\t\tcomponents.push(\n\t\t\tWidgetContainer\n\t\t);\n\t\treturn components;\n\t} );\n\n\twp.hooks.addFilter(\n\t\t'payoneer-checkout_payment_method_icons',\n\t\t'payoneer-checkout',\n\t\t(icons) => {\n\t\t\tconst activePaymentMethod = payoneerStore.getActivePaymentMethod();\n\t\t\treturn activePaymentMethod === 'payoneer-checkout' ? [] : icons\n\t\t}\n\t);\n};\n\nconst registerPageReloadingOnPaymentDeclined = () => {\n\tdocument.addEventListener(\n\t\t'DOMContentLoaded',\n\t\t() => {\n\t\t\twp.hooks.addFilter(\n\t\t\t\t'payoneer.webSdk.onPaymentDeclined',\n\t\t\t\t'payoneer/blockCheckout',\n\t\t\t\t() => {\n\t\t\t\t\twp.data.dispatch(PAYONEER_STORE_KEY).releaseOnHoldOrder(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlongId: select( PAYONEER_STORE_KEY ).getLongId(),\n\t\t\t\t\t\t\tpayoneerOrderId: select(PAYONEER_STORE_KEY).getOrderId()\n\t\t\t\t\t\t},\n\t\t\t\t\t);\n\t\t\t\t\t/**\n\t\t\t\t\t * The following is an extreme solution where a correct solution seemingly does not exist.\n\t\t\t\t\t * As of 02/2025, the WooCommerce checkout entirely depends on a redirectUrl after onCheckoutSuccess().\n\t\t\t\t\t * If there is no redirect, core WC will simply do nothing, leaving a nonfunctional checkout page\n\t\t\t\t\t * with a greyed-out blocked Pay button.\n\t\t\t\t\t * You can test this by out-commenting the payment call in our 'onCheckoutSuccess' observer.\n\t\t\t\t\t *\n\t\t\t\t\t * Now:\n\t\t\t\t\t * Our WC backend cannot dictate a redirectUrl because we will only start the client-side CHARGE\n\t\t\t\t\t * after creating the order in the backend. Thus, the backend only finalizes LIST data.\n\t\t\t\t\t * It is the job of the WebSDK to carry out the payment and handle the redirects.\n\t\t\t\t\t * On the happy path, this is not an issue.\n\t\t\t\t\t *\n\t\t\t\t\t * But what if there is an error?\n\t\t\t\t\t * component.pay() is async, but onCheckoutSuccess() can only be influenced synchronously, by returning\n\t\t\t\t\t * success/failure. But we cannot know that since we are not omniscient time-bending 4D creatures yet.\n\t\t\t\t\t *\n\t\t\t\t\t * So since we cannot give WC any meaningful signal before resolving the async call,\n\t\t\t\t\t * we are forced to accept its default behaviour: redirecting to 'redirectUrl' which is empty,\n\t\t\t\t\t * leading to the aforementioned blocked checkout state.\n\t\t\t\t\t *\n\t\t\t\t\t * The only known recovery is dispatch(CHECKOUT_STORE_KEY).__internalSetIdle()\n\t\t\t\t\t * However, that's using an internal function that might be unsafe and could be removed any time.\n\t\t\t\t\t *\n\t\t\t\t\t * So we're picking the heavy tools when they are required. Hints and PRs welcome.\n\t\t\t\t\t *\n\t\t\t\t\t * @see https://developer.woocommerce.com/docs/cart-and-checkout-checkout-flow-and-events/\n\t\t\t\t\t */\n\t\t\t\t\twindow.location.reload();\n\t\t\t\t\treturn true // just out of spite\n\t\t\t\t}\n\t\t\t);\n\t\t},\n\t\tfalse\n\t);\n}\n\nexport const initBlockCheckout = () => {\n\tconsole.log('Loading classic checkout integration')\n\tsetUpBlockCheckoutListeners();\n\tsetUpGatewayContainers();\n\tregisterPageReloadingOnPaymentDeclined();\n}\n","import { isBlockCheckout, isPayForOrder } from './src/util/woocommerce';\nimport { setupCustomHttpHeaders } from './src/util/http';\nimport { initClassicCheckout } from \"./src/util/checkout/classicCheckout\";\nimport { initBlockCheckout } from \"./src/util/checkout/blockCheckout\";\nimport { initPaymentCheckout } from \"./src/util/checkout/paymentCheckout\";\n\n\ndocument.addEventListener(\n\t'DOMContentLoaded',\n\tsetupCustomHttpHeaders,\n\tfalse\n);\n/**\n * Boot one of the supported checkout integrations.\n * Let us hope this list is getting shorter, not longer\n */\nif ( isPayForOrder() ) {\n\tinitPaymentCheckout()\n} else if ( isBlockCheckout() ) {\n\tinitBlockCheckout();\n} else {\n\tinitClassicCheckout()\n}\n\n","import { setupClassicCheckoutListeners } from \"../../store/storeListeners\";\nimport $ from \"jquery\";\nimport {\n\tisPayForOrder,\n\tisPayoneerGatewaySelected,\n\tsubmitOrderPayViaAjax,\n\tfocusOnSelectedGateway\n} from \"../woocommerce\";\nimport { PAYONEER_STORE_KEY } from \"../../store\";\nimport { defaultHooks } from '@wordpress/hooks';\nimport { select, dispatch } from '@wordpress/data';\nimport { releaseOnHoldOrder, setOnPaymentDeclinedNonce } from \"../../store/actions\";\n\n\nexport const initPaymentCheckout = () => {\n\tconsole.log('Loading payment checkout integration')\n\n\tdocument.addEventListener(\n\t\t'DOMContentLoaded',\n\t\t() => {\n\t\t\tsetupClassicCheckoutListeners()\n\t\t\tdispatch(PAYONEER_STORE_KEY).\n\t\t\t\tsetOnPaymentDeclinedNonce(PayoneerData.onPaymentDeclinedNonce);\n\n\t\t\tconst $orderReviewForm = $( '#order_review' );\n\n\t\t\tdefaultHooks.addFilter(\n\t\t\t\t'payoneer.webSdk.onSdkError',\n\t\t\t\t'payoneer/paymentCheckout',\n\t\t\t\t( isResolved, checkout, component, data ) => {\n\t\t\t\t\tconst { payOrderErrorFlag } = window.PayoneerData;\n\t\t\t\t\tconst url = new URL( document.location );\n\t\t\t\t\turl.searchParams.set( payOrderErrorFlag, true );\n\t\t\t\t\twindow.location.href = url.toString();\n\t\t\t\t\treturn isResolved;\n\t\t\t\t}\n\t\t\t);\n\n\t\t\twp.hooks.addFilter(\n\t\t\t\t'payoneer.webSdk.onPaymentDeclined',\n\t\t\t\t'payoneer/paymentCheckout',\n\t\t\t\tasync () => {\n\t\t\t\t\tawait wp.data.dispatch(PAYONEER_STORE_KEY).releaseOnHoldOrder(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlongId: select( PAYONEER_STORE_KEY ).getLongId(),\n\t\t\t\t\t\t\torderKey: new URLSearchParams(window.location.search).get('key'),\n\t\t\t\t\t\t},\n\t\t\t\t\t);\n\t\t\t\t\twindow.location.reload();\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t);\n\n\t\t\t$orderReviewForm.on( 'submit', ( e ) => {\n\t\t\t\tif ( !isPayoneerGatewaySelected() || select( PAYONEER_STORE_KEY ).isHostedModeForced() ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\te.preventDefault();\n\t\t\t\te.stopImmediatePropagation();\n\n\t\t\t\tconst isValid = select( PAYONEER_STORE_KEY ).getIsValid();\n\n\t\t\t\tif ( !isValid ) {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tfocusOnSelectedGateway();\n\t\t\t\t\t} catch (error){\n\t\t\t\t\t\tconsole.error(error);\n\t\t\t\t\t} finally {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t\tsubmitOrderPayViaAjax( $orderReviewForm )\n\t\t\t\t\t.then( () => dispatch( PAYONEER_STORE_KEY ).pay() )\n\t\t\t\t\t.catch( () => {\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * Reloading enables us to see error messages added via wc_add_notice()\n\t\t\t\t\t\t * Scrolling up makes sure the notices are in the viewport after the refresh\n\t\t\t\t\t\t */\n\t\t\t\t\t\twindow.scrollTo( 0, 0 );\n\t\t\t\t\t\twindow.location.reload();\n\t\t\t\t\t} );\n\t\t\t} );\n\n\t\t\tdispatch( PAYONEER_STORE_KEY ).mountComponents();\n\t\t},\n\t\tfalse\n\t);\n}\n","import { setupClassicCheckoutListeners } from \"../../store/storeListeners\";\nimport $ from \"jquery\";\nimport {\n\tgetSelectedPaymentBox,\n\tisPayoneerGatewaySelected,\n\tfocusOnSelectedGateway\n} from \"../woocommerce\";\nimport { PAYONEER_STORE_KEY } from \"../../store\";\nimport { defaultHooks } from '@wordpress/hooks';\nimport { select, dispatch } from '@wordpress/data';\nimport { releaseOnHoldOrder, setOnPaymentDeclinedNonce } from \"../../store/actions\";\n\nexport const initClassicCheckout = () => {\n\tconsole.log('Loading classic checkout integration')\n\tdocument.addEventListener(\n\t\t'DOMContentLoaded',\n\t\t() => {\n\t\t\tsetupClassicCheckoutListeners()\n\t\t\tdispatch(PAYONEER_STORE_KEY)\n\t\t\t\t.setOnPaymentDeclinedNonce(PayoneerData.onPaymentDeclinedNonce);\n\n\t\t\tconst $checkoutForm = $( 'form.checkout' );\n\n\t\t\tdefaultHooks.addFilter(\n\t\t\t\t'payoneer.webSdk.onSdkError',\n\t\t\t\t'payoneer/shortcodeCheckout',\n\t\t\t\t( isResolved, checkout, component, data ) => {\n\t\t\t\t\twp.data.dispatch(PAYONEER_STORE_KEY).reboot();\n\n\t\t\t\t\t$( document.body ).trigger( 'update_checkout' );\n\t\t\t\t\treturn isResolved\n\t\t\t\t}\n\t\t\t);\n\n\t\t\twp.hooks.addFilter(\n\t\t\t\t'payoneer.webSdk.onPaymentDeclined',\n\t\t\t\t'payoneer/shortcodeCheckout',\n\t\t\t\t() => {\n\t\t\t\t\twp.data.dispatch(PAYONEER_STORE_KEY).releaseOnHoldOrder(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlongId: select( PAYONEER_STORE_KEY ).getLongId(),\n\t\t\t\t\t\t},\n\t\t\t\t\t);\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t);\n\n\t\t\t/**\n\t\t\t * Cannot use native event listener for events dispatched by jQuery\n\t\t\t * https://github.com/jquery/jquery/issues/3347\n\t\t\t */\n\t\t\t$( document.body ).on( 'updated_checkout', () => dispatch( PAYONEER_STORE_KEY ).initPayoneerComponents() );\n\n\t\t\t$checkoutForm.on('checkout_place_order', () => {\n\t\t\t\tconst isValid = select( PAYONEER_STORE_KEY ).getIsValid();\n\t\t\t\tif ( isValid ) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tfocusOnSelectedGateway();\n\t\t\t\t} catch(error) {\n\t\t\t\t\tconsole.error(error);\n\t\t\t\t} finally {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t} );\n\n\t\t\t$checkoutForm.on( 'checkout_place_order_success', ( e, result ) => {\n\t\t\t\tif ( !isPayoneerGatewaySelected() || select( PAYONEER_STORE_KEY ).isHostedModeForced() ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tdispatch( PAYONEER_STORE_KEY ).pay();\n\n\t\t\t\t//Override default redirect to hosted payment page\n\t\t\t\tresult.redirect = '#payoneer-redirect';\n\n\t\t\t\t/**\n\t\t\t\t * Create a timeout that races the SDK's payment handling.\n\t\t\t\t * If the handling is not done after 1,5 second, it unblocks\n\t\t\t\t * the checkout form and scrolls the users to the payment fields\n\t\t\t\t * because probably there is an error displayed there\n\t\t\t\t *\n\t\t\t\t * This is done since the SDK does not have any validation callback\n\t\t\t\t * or Promise we could attach to.\n\t\t\t\t */\n\t\t\t\tsetTimeout( () => {\n\t\t\t\t\t$checkoutForm.removeClass( 'processing' ).unblock();\n\t\t\t\t\t$.scroll_to_notices(\n\t\t\t\t\t\t$( getSelectedPaymentBox() )\n\t\t\t\t\t);\n\t\t\t\t}, 1500 );\n\n\t\t\t\treturn false;\n\t\t\t} );\n\t\t},\n\t\tfalse\n\t);\n}\n"],"names":["f","k","Symbol","for","m","Object","prototype","hasOwnProperty","n","__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED","ReactCurrentOwner","p","key","ref","__self","__source","exports","jsx","c","a","g","b","d","e","h","call","defaultProps","$$typeof","type","props","_owner","current","module","window","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","__webpack_modules__","getter","__esModule","definition","o","defineProperty","enumerable","get","obj","prop","r","toStringTag","value","paymentFieldsComponentAttribute","PayoneerData","selectedPaymentGateway","document","querySelector","selectedPaymentGatewayId","id","isPayoneerGatewaySelected","isPayoneerGateway","gatewayId","test","isPayForOrder","focusOnSelectedGateway","focus","ACTIONS","SET_EXTENSION_DATA","SET_LONG_ID","SET_LIST_URL","SET_ENV","SET_SDK","SET_SDK_VERSION","SET_SDK_INTEGRITY","SET_SDK_STATE","ADD_COMPONENT","REMOVE_COMPONENT","MOUNT_COMPONENTS","PAY","SET_ACTIVE_PAYMENT_METHOD","SET_FORCE_HOSTED_FLOW","SET_IS_VALID","SET_ORDER_ID","SET_ON_PAYMENT_DECLINED_NONCE","initialState","activePaymentMethod","longId","env","sdkState","forceHostedFlow","isValid","availableDropInComponents","getComponentNameByGatewayId","mountComponents","components","sdk","componentName","component","entries","container","findComponentContainer","Element","isAvailable","mount","setLongId","async","select","resolveSelect","dispatch","getSdk","updateLongId","payload","setSdkState","setEnv","addComponent","console","log","isDroppedIn","name","dropIn","hidePaymentButton","doMountComponents","error","removeComponent","initPayoneerComponents","getLongId","reboot","defaultHooks","doAction","wp","data","invalidateResolutionForStore","availableComponents","getAvailableDropInComponents","pay","getActivePaymentMethod","onBeforeError","state","includes","interaction","reason","setForceHostedFlow","applyFilters","onPaymentDeclined","onComponentListChange","changeInfo","addedComponents","forEach","removedComponents","onValidationInfo","setIsValid","valid","setActivePaymentMethod","method","flag","setOnPaymentDeclinedNonce","nonce","setOrderId","orderId","releaseOnHoldOrder","requestData","targetUrlBase","wc_checkout_params","wc_ajax_url","toString","replace","separator","targetUrl","onPaymentDeclinedNonce","Promise","resolve","reject","$","url","xhrFields","withCredentials","dataType","success","catch","websdkStyles","styles","getEnv","sdkVersion","getSdkVersion","sdkIntegrity","getSdkIntegrity","config","preload","Payoneer","CheckoutWeb","script","createElement","src","formatUmdUrl","scriptVersion","URL","webSdkUmdUrlTemplate","onload","onerror","integrity","crossOrigin","head","appendChild","then","nonLoadingState","interval","setInterval","clearInterval","getExtensionData","response","apiFetch","path","cache","parse","payoneerExtensionData","json","extensions","extensionData","environment","PAYONEER_STORE_KEY","payoneerStore","createReduxStore","reducer","action","extension","listUrl","actions","selectors","isHostedModeForced","getIsValid","getOrderId","getOnPaymentDeclinedNonce","resolvers","register","FORCE_HOSTED_MODE_HEADER","IS_PAYMENT_CHECKOUT","getCustomHeaders","customHeaders","String","URLSearchParams","location","search","addAction","addFilter","headers","setupClassicCheckoutListeners","paymentMethodCallback","methodName","_document$querySelect","paymentMethodName","jQuery","body","on","payWithPayoneer","rebootPayoneer","WidgetContainer","withSelect","ownProps","payoneer","eventRegistration","provider","paymentMethodData","onPaymentSetup","onCheckoutSuccess","onCheckoutFail","useEffect","message","_jsx","className","addEventListener","originalFetch","fetch","args","options","origin","XMLHttpRequest","originalOpen","open","originalSend","send","rest","this","_isSameOrigin","apply","header","setRequestHeader","$orderReviewForm","isResolved","checkout","payOrderErrorFlag","searchParams","set","href","hooks","orderKey","reload","preventDefault","stopImmediatePropagation","$form","block","overlayCSS","background","opacity","ajax_url","fields","serialize","params","always","unblock","scrollTo","isBlockCheckout","setUpBlockCheckoutListeners","currentPaymentMethod","wcPaymentStore","PAYMENT_STORE_KEY","paymentStoreCallback","paymentMethod","subscribe","Array","isArray","inpsydeGateways","gatewayName","push","icons","payoneerOrderId","$checkoutForm","trigger","result","redirect","setTimeout","removeClass","selector","getPaymentBox"],"sourceRoot":""}
     1{"version":3,"file":"payoneer-checkout.js","mappings":"uDASiBA,EAAE,EAAQ,KAASC,EAAEC,OAAOC,IAAI,iBAAgDC,GAA7BF,OAAOC,IAAI,kBAAoBE,OAAOC,UAAUC,gBAAeC,EAAER,EAAES,mDAAmDC,kBAAkBC,EAAE,CAACC,KAAI,EAAGC,KAAI,EAAGC,QAAO,EAAGC,UAAS,GAC+FC,EAAQC,IAAvV,SAAWC,EAAEC,EAAEC,GAAG,IAAIC,EAAEC,EAAE,CAAC,EAAEC,EAAE,KAAKC,EAAE,KAAiF,IAAIH,UAAhF,IAASD,IAAIG,EAAE,GAAGH,QAAG,IAASD,EAAEP,MAAMW,EAAE,GAAGJ,EAAEP,UAAK,IAASO,EAAEN,MAAMW,EAAEL,EAAEN,KAAcM,EAAEf,EAAEqB,KAAKN,EAAEE,KAAKV,EAAEJ,eAAec,KAAKC,EAAED,GAAGF,EAAEE,IAAI,GAAGH,GAAGA,EAAEQ,aAAa,IAAIL,KAAKF,EAAED,EAAEQ,kBAAe,IAASJ,EAAED,KAAKC,EAAED,GAAGF,EAAEE,IAAI,MAAM,CAACM,SAAS1B,EAAE2B,KAAKV,EAAEN,IAAIW,EAAEV,IAAIW,EAAEK,MAAMP,EAAEQ,OAAOtB,EAAEuB,QAAQ,C,kBCV3TC,EAAOhB,QAAUiB,OAAc,K,sBCG7BD,EAAOhB,QAAU,EAAjB,G,GCFEkB,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA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B5D,mBACpC,CACCzE,QAAQoB,EAAAA,EAAAA,QAAQiH,GAAqB9F,eAGhC,IAQT+C,IAAGrH,SAASoM,MAAOC,GAAI,mBAAoB,KAAMhJ,EAAAA,EAAAA,UAAU+G,GAAqB/F,0BAEhFyM,EAAczE,GAAG,uBAAwB,KAExC,IADgBlJ,EAAAA,EAAAA,QAAQiH,GAAqBU,aAE5C,OAAO,EAGR,IACCrK,GACD,CAAE,MAAM0D,GACPP,QAAQO,MAAMA,EACf,CAAE,QACD,OAAO,CACR,IAGD2M,EAAczE,GAAI,+BAAgC,CAAErO,EAAGgT,KACtD,GAAM5Q,OAA+B+C,EAAAA,EAAAA,QAAQiH,GAAqBS,qBAwBlE,OArBAxH,EAAAA,EAAAA,UAAU+G,GAAqBrF,MAG/BiM,EAAOC,SAAW,qBAWlBC,WAAY,KACXJ,EAAcK,YAAa,cAAetB,UAC1CxI,IAAAA,kBACCA,IrBrDyB/G,KAC9B,MAAM8Q,EAAW,gBAAkB9Q,EACnC,OAAON,SAASC,cAAemR,IAI/BC,CAAenR,QqBiDT,OAEI,MAGT,G","sources":["webpack://payoneer-embedded-payment/./node_modules/react/cjs/react-jsx-runtime.production.min.js","webpack://payoneer-embedded-payment/external window \"React\"","webpack://payoneer-embedded-payment/./node_modules/react/jsx-runtime.js","webpack://payoneer-embedded-payment/webpack/bootstrap","webpack://payoneer-embedded-payment/webpack/runtime/compat get default export","webpack://payoneer-embedded-payment/webpack/runtime/define property getters","webpack://payoneer-embedded-payment/webpack/runtime/hasOwnProperty shorthand","webpack://payoneer-embedded-payment/webpack/runtime/make namespace object","webpack://payoneer-embedded-payment/external window \"jQuery\"","webpack://payoneer-embedded-payment/./resources/js/src/util/woocommerce.js","webpack://payoneer-embedded-payment/external window [\"wp\",\"data\"]","webpack://payoneer-embedded-payment/./resources/js/src/store/constants.js","webpack://payoneer-embedded-payment/./resources/js/src/store/reducer.js","webpack://payoneer-embedded-payment/./resources/js/src/util/components.js","webpack://payoneer-embedded-payment/external window [\"wp\",\"hooks\"]","webpack://payoneer-embedded-payment/./resources/js/src/store/actions.js","webpack://payoneer-embedded-payment/./resources/js/src/util/sdk/umdLoader.js","webpack://payoneer-embedded-payment/external window [\"wp\",\"apiFetch\"]","webpack://payoneer-embedded-payment/./resources/js/src/store/resolvers.js","webpack://payoneer-embedded-payment/./resources/js/src/store/index.js","webpack://payoneer-embedded-payment/./resources/js/src/store/selectors.js","webpack://payoneer-embedded-payment/./resources/js/src/util/http.js","webpack://payoneer-embedded-payment/external window [\"wc\",\"wcBlocksData\"]","webpack://payoneer-embedded-payment/./resources/js/src/store/storeListeners.js","webpack://payoneer-embedded-payment/./resources/js/src/components/widgetContainer/component.js","webpack://payoneer-embedded-payment/./resources/js/src/components/widgetContainer/provider.js","webpack://payoneer-embedded-payment/./resources/js/src/components/widgetContainer/index.js","webpack://payoneer-embedded-payment/./resources/js/src/util/checkout/blockCheckout.js","webpack://payoneer-embedded-payment/./resources/js/payoneer-checkout.js","webpack://payoneer-embedded-payment/./resources/js/src/util/checkout/paymentCheckout.js","webpack://payoneer-embedded-payment/./resources/js/src/util/checkout/classicCheckout.js"],"sourcesContent":["/**\n * @license React\n * react-jsx-runtime.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var f=require(\"react\"),k=Symbol.for(\"react.element\"),l=Symbol.for(\"react.fragment\"),m=Object.prototype.hasOwnProperty,n=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p={key:!0,ref:!0,__self:!0,__source:!0};\nfunction q(c,a,g){var b,d={},e=null,h=null;void 0!==g&&(e=\"\"+g);void 0!==a.key&&(e=\"\"+a.key);void 0!==a.ref&&(h=a.ref);for(b in a)m.call(a,b)&&!p.hasOwnProperty(b)&&(d[b]=a[b]);if(c&&c.defaultProps)for(b in a=c.defaultProps,a)void 0===d[b]&&(d[b]=a[b]);return{$$typeof:k,type:c,key:e,ref:h,props:d,_owner:n.current}}exports.Fragment=l;exports.jsx=q;exports.jsxs=q;\n","module.exports = window[\"React\"];","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n  module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n  module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"jQuery\"];","import $ from 'jquery';\nconst {\n\tpaymentFieldsComponentAttribute\n} = window.PayoneerData;\n\nexport const paymentMethodName = () => {\n\treturn document.querySelector( '.woocommerce-checkout input[name=\"payment_method\"]:checked' ).value ?? '';\n}\n\nexport const selectedPaymentGateway = () => {\n\treturn document.querySelector(\n\t\t'.woocommerce-checkout input[name=\"payment_method\"]:checked'\n\t)\n};\n\nexport const selectedPaymentGatewayId = () => {\n\treturn selectedPaymentGateway()?.id;\n};\n\nexport const getComponentNameFromPaymentBox = function ( paymentBox ) {\n\treturn paymentBox\n\t\t?.querySelector( `[${ paymentFieldsComponentAttribute }]` )\n\t\t?.getAttribute( paymentFieldsComponentAttribute );\n};\n\nexport const isPayoneerGateway = ( gatewayId ) => {\n\treturn /^payment_method_payoneer-(checkout|afterpay)/i.test( gatewayId );\n};\n\nexport const isPayoneerGatewaySelected = () =>\n\tisPayoneerGateway( selectedPaymentGatewayId() );\n\nexport const isPayForOrder = () => {\n\treturn window.PayoneerData.isPayForOrder === '1';\n};\n\nexport const getPaymentBox = ( gatewayId ) => {\n\tconst selector = '.payment_box.' + gatewayId;\n\treturn document.querySelector( selector );\n};\n\nexport const getSelectedPaymentBox = () =>\n\tgetPaymentBox( selectedPaymentGatewayId() );\n\nconst hostedOverrideFlagInput = () => {\n\tconst { hostedFlowOverrideFlag } = window.PayoneerData;\n\treturn document.querySelector(\n\t\t`input[name=\"${ hostedFlowOverrideFlag }\"]`\n\t);\n};\n\nexport const submitOrderPayViaAjax = ( $form ) => {\n\t//Blocks the UI in the same way Woocommerce does (source: https://github.com/woocommerce/woocommerce/blob/6.0.1/plugins/woocommerce/assets/js/frontend/checkout.js#L454-L466)\n\t$form.block( {\n\t\tmessage: null,\n\t\toverlayCSS: {\n\t\t\tbackground: '#fff',\n\t\t\topacity: 0.6,\n\t\t},\n\t} );\n\n\treturn $.ajax( {\n\t\ttype: 'POST',\n\t\turl: window.wc_checkout_params.ajax_url,\n\t\txhrFields: {\n\t\t\t// This is important. We need the session cookie to access the LIST in the back-end\n\t\t\twithCredentials: true,\n\t\t},\n\t\tdataType: 'json',\n\t\tdata: {\n\t\t\taction: 'payoneer_order_pay',\n\t\t\tfields: $form.serialize(),\n\t\t\tparams: new URL( document.location ).searchParams.toString(),\n\t\t},\n\t} ).always( () => $form.unblock() );\n};\n\nexport const isBlockCheckout = () =>\n\twindow?.PayoneerData?.isBlockCheckout === '1';\n\nexport const focusOnSelectedGateway = () => {\n\tselectedPaymentGateway()?.focus();\n}\n","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"data\"];","export const ACTIONS = {\n\tSET_EXTENSION_DATA: 'SET_EXTENSION_DATA',\n\tSET_LONG_ID: 'SET_LONG_ID',\n\tSET_LIST_URL: 'SET_LIST_URL',\n\tSET_ENV: 'SET_ENV',\n\tSET_SDK: 'SET_SDK',\n\tSET_SDK_VERSION: 'SET_SDK_VERSION',\n\tSET_SDK_INTEGRITY: 'SET_SDK_INTEGRITY',\n\tSET_SDK_STATE: 'SET_SDK_STATE',\n\tADD_COMPONENT: 'ADD_COMPONENT',\n\tREMOVE_COMPONENT: 'REMOVE_COMPONENT',\n\tMOUNT_COMPONENTS: 'MOUNT_COMPONENTS',\n\tPAY: 'PAY',\n\tSET_ACTIVE_PAYMENT_METHOD: 'SET_ACTIVE_PAYMENT_METHOD',\n\tSET_FORCE_HOSTED_FLOW: 'SET_FORCE_HOSTED_FLOW',\n\tSET_IS_VALID: 'SET_IS_VALID',\n\tSET_ORDER_ID: 'SET_ORDER_ID',\n\tSET_ON_PAYMENT_DECLINED_NONCE: 'SET_ON_PAYMENT_DECLINED_NONCE',\n};\n","import { ACTIONS } from './constants';\n\nconst initialState = {\n\tactivePaymentMethod: '',\n\tlongId: null,\n\tenv: null,\n\tsdkState: 'UNINITIALIZED',\n\tforceHostedFlow: true,\n\tisValid: false,\n\tavailableDropInComponents: []\n};\n\nconst reducer = (state = initialState, action) => {\n\tswitch (action.type) {\n\t\tcase ACTIONS.SET_EXTENSION_DATA:\n\t\t\treturn { ...state, extension: action.payload };\n\t\tcase ACTIONS.SET_LONG_ID:\n\t\t\treturn { ...state, longId: action.payload };\n\t\tcase ACTIONS.SET_LIST_URL:\n\t\t\treturn { ...state, listUrl: action.payload };\n\t\tcase ACTIONS.SET_ENV:\n\t\t\treturn { ...state, env: action.payload };\n\t\tcase ACTIONS.SET_SDK:\n\t\t\treturn { ...state, sdk: action.payload };\n\t\tcase ACTIONS.SET_SDK_VERSION:\n\t\t\treturn { ...state, sdkVersion: action.payload };\n\t\tcase ACTIONS.SET_SDK_INTEGRITY:\n\t\t\treturn { ...state, sdkIntegrity: action.payload };\n\t\tcase ACTIONS.SET_SDK_STATE:\n\t\t\treturn { ...state, sdkState: action.payload };\n\t\tcase ACTIONS.SET_ACTIVE_PAYMENT_METHOD:\n\t\t\treturn { ...state, activePaymentMethod: action.payload };\n\t\tcase ACTIONS.SET_FORCE_HOSTED_FLOW:\n\t\t\treturn { ...state, forceHostedFlow: action.payload };\n\t\tcase ACTIONS.SET_IS_VALID:\n\t\t\treturn { ...state, isValid: action.payload };\n\t\tcase ACTIONS.SET_ORDER_ID:\n\t\t\treturn { ...state, orderId: action.payload };\n\t\tcase ACTIONS.SET_ON_PAYMENT_DECLINED_NONCE:\n\t\t\treturn { ...state, onPaymentDeclinedNonce: action.payload };\n\t\tcase ACTIONS.ADD_COMPONENT:\n\t\t\treturn {\n\t\t\t\t...state,\n\t\t\t\tavailableDropInComponents: {\n\t\t\t\t\t...state.availableDropInComponents,\n\t\t\t\t\t[action.payload.name]: action.payload.component\n\t\t\t\t}\n\t\t\t};\n\t\tcase ACTIONS.REMOVE_COMPONENT:\n\t\t\tlet availableDropInComponents = { ...state.availableDropInComponents };\n\t\t\tdelete availableDropInComponents[action.payload.name];\n\t\t\treturn { ...state, availableDropInComponents };\n\t\tdefault:\n\t\t\treturn state;\n\t}\n};\n\nexport default reducer;\n","import {\n\tgetPaymentBox,\n\tgetComponentNameFromPaymentBox,\n\tsetHostedOverride\n} from './woocommerce';\n\nexport const getComponentNameByGatewayId = ( gatewayId ) => {\n\tconst gatewayIdToComponentName = {\n\t\t'payoneer-checkout': 'cards',\n\t\t'payoneer-afterpay': 'afterpay',\n\t};\n\n\treturn gatewayIdToComponentName[ gatewayId ];\n}\n\nconst { paymentFieldsComponentAttribute } = window.PayoneerData;\n\nexport const mountComponents = ( components, sdk ) => {\n\tfor ( const [ componentName, component ] of Object.entries( components ) ) {\n\t\tconst container = findComponentContainer( componentName );\n\t\tif (\n\t\t\tcontainer instanceof Element &&\n\t\t\tsdk.isAvailable( componentName )\n\t\t) {\n\t\t\tcomponent.mount( container );\n\t\t}\n\t}\n};\n\nexport const findComponentContainer = function ( componentName ) {\n\treturn document.querySelector(\n\t\t`[${paymentFieldsComponentAttribute}=${componentName}]`\n\t);\n};\n","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"hooks\"];","import {\n\tmountComponents as doMountComponents,\n\tgetComponentNameByGatewayId,\n\tfindComponentContainer\n} from '../util/components';\nimport { ACTIONS } from './constants';\nimport { defaultHooks } from \"@wordpress/hooks\";\nimport $ from 'jquery';\n\nexport const setLongId = ( longId ) => async ( { select, resolveSelect, dispatch } ) => {\n\tconst sdk = await resolveSelect.getSdk()\n\tawait sdk.updateLongId( longId );\n\tdispatch( { type: ACTIONS.SET_LONG_ID, payload: longId } );\n}\n\nexport const setSdkState = ( sdkState ) => {\n\treturn { type: ACTIONS.SET_SDK_STATE, payload: sdkState };\n};\n\nexport function setEnv( env ) {\n\treturn { type: ACTIONS.SET_ENV, payload: env };\n}\n\nexport const addComponent = ( componentName ) => async ( { select, resolveSelect, dispatch } ) => {\n\tconst sdk = await resolveSelect.getSdk()\n\tconsole.log( sdk )\n\tif ( !sdk.isDroppedIn( componentName ) && typeof findComponentContainer( componentName ) === 'object' ) {\n\t\ttry {\n\t\t\tconst payload = {\n\t\t\t\tname: componentName,\n\t\t\t\tcomponent: sdk.dropIn( componentName, {\n\t\t\t\t\thidePaymentButton: true,\n\t\t\t\t} )\n\t\t\t};\n\t\t\tconsole.log( 'New component', payload );\n\t\t\tdispatch( { type: ACTIONS.ADD_COMPONENT, payload } );\n\t\t\tdoMountComponents( { [ payload.name ]: payload.component }, sdk );\n\t\t} catch ( e ) {\n\t\t\tconsole.error( `Failed to drop in component ${componentName}. Error details: ${e}` );\n\t\t}\n\t}\n}\n\nexport function removeComponent( componentName ) {\n\treturn { type: ACTIONS.REMOVE_COMPONENT, payload: componentName };\n}\n\n/**\n * When a React component is displayed for the first time, the SDK needs to mount its dropIn.\n * So they call this function in a useEffect callback.\n * However:\n * If the SDK has been bootstrapped already, and a new method becomes available after\n * checkout field changes we need to instruct the SDK to refetch the list of dropIn components.\n * This is why we call sdk.updateLongId()\n * After that, the onComponentListChange handler should take care of mounting automatically\n *\n * @returns {(function({select: *, resolveSelect: *, dispatch: *}): Promise<void>)|*}\n */\nexport const initPayoneerComponents = () => async ( { select, resolveSelect, dispatch } ) => {\n\tconst sdk = await resolveSelect.getSdk()\n\tconst longId = await resolveSelect.getLongId()\n\tawait sdk.updateLongId( longId );\n\tawait dispatch.mountComponents()\n}\n\nexport const reboot = () => async ( { select, resolveSelect, dispatch } ) => {\n\tdefaultHooks.doAction( 'payoneer.webSdk.reboot' )\n\twp.data.dispatch( 'wc/store/cart' ).invalidateResolutionForStore();\n\tdispatch.invalidateResolutionForStore()\n\tawait dispatch.mountComponents()\n}\n\nexport const mountComponents = () => async ( { select, resolveSelect, dispatch } ) => {\n\tconst sdk = await resolveSelect.getSdk()\n\tconst availableComponents = select.getAvailableDropInComponents();\n\tconsole.log( 'Mounting components', availableComponents );\n\tdoMountComponents( availableComponents, sdk );\n};\n\nexport const pay = () => ( { select, dispatch } ) => {\n\tconst availableComponents = select.getAvailableDropInComponents();\n\tconst activePaymentMethod = select.getActivePaymentMethod();\n\tconst componentName = getComponentNameByGatewayId( activePaymentMethod );\n\tconst component = availableComponents[ componentName ];\n\tif ( !component ) {\n\t\tconsole.log( 'Component not found.' );\n\t\treturn;\n\t}\n\tcomponent.pay();\n};\n\nexport const onBeforeError = ( sdk, component, data ) => async ( { select, dispatch } ) => {\n\tdispatch.setSdkState( sdk.state );\n\tconsole.error( \"WebSDK error:\", { sdk, component, data } );\n\t/**\n\t * For SYSTEM_FAILURE, we assume there is nothing we can do to recover.\n\t * Use hosted mode fallback and let the customer proceed\n\t */\n\tif ( [ \"SYSTEM_FAILURE\" ].includes( data?.interaction?.reason ) ) {\n\t\tdispatch.setForceHostedFlow( true );\n\t\treturn true;\n\t}\n\t/**\n\t * Let the outside world attempt to handle the error.\n\t * The different checkout types can reboot the payment attempt from there.\n\t */\n\treturn defaultHooks.applyFilters( 'payoneer.webSdk.onSdkError', false, sdk, component, data );\n}\n\nexport const onPaymentDeclined = ( sdk, component, data ) => async ( { select, dispatch } ) => {\n\treturn defaultHooks.applyFilters( 'payoneer.webSdk.onPaymentDeclined', true, sdk, component, data )\n}\n\nexport const onComponentListChange = ( sdk, changeInfo ) => async ( { select, dispatch } ) => {\n\tconsole.log( 'onComponentListChange', sdk, changeInfo );\n\tchangeInfo.addedComponents.forEach( ( name ) => {\n\t\tdispatch.addComponent( name );\n\t} );\n\tchangeInfo.removedComponents.forEach( ( name ) => {\n\t\tdispatch.removeComponent( name );\n\t} );\n}\nexport const onValidationInfo = ( sdk, componentName, data ) => async ( { select, dispatch } ) => {\n\tconsole.log(componentName,data)\n\tdispatch.setIsValid( data.valid )\n}\n\nexport const setActivePaymentMethod = ( method ) => async ( { dispatch } ) => {\n\tconsole.log( 'Setting active payment method', method );\n\tdispatch.mountComponents()\n\tdispatch( { type: ACTIONS.SET_ACTIVE_PAYMENT_METHOD, payload: method } );\n}\n\nexport function setForceHostedFlow( state ) {\n\tconsole.log( 'Setting hosted flow override flag', state );\n\treturn { type: ACTIONS.SET_FORCE_HOSTED_FLOW, payload: state };\n}\n\nexport function setIsValid( flag ) {\n\treturn { type: ACTIONS.SET_IS_VALID, payload: flag };\n}\n\nexport const setOnPaymentDeclinedNonce = ( nonce ) => ( {dispatch} ) => {\n\tdispatch( { type: ACTIONS.SET_ON_PAYMENT_DECLINED_NONCE, payload: nonce} );\n}\n\nexport const setOrderId = ( orderId ) => ( {dispatch} ) => {\n\tdispatch( { type: ACTIONS.SET_ORDER_ID, payload: orderId } );\n}\n\nexport const releaseOnHoldOrder = (requestData) => async ( { dispatch } ) => {\n\tconst targetUrlBase = window.wc_checkout_params.wc_ajax_url.\n\ttoString().\n\treplace( '%%endpoint%%', 'payoneer-checkout-payment-declined' );\n\tconst separator = targetUrlBase.includes('?') ? '&' : '?';\n\tconst targetUrl = targetUrlBase +\n\t\tseparator +\n\t\t'_ajax_nonce=' +\n\t\twindow.PayoneerData.onPaymentDeclinedNonce\n\n\treturn new Promise( ( resolve, reject ) => {\n\t\t$.ajax( {\n\t\t\ttype: 'POST',\n\t\t\turl: targetUrl,\n\t\t\txhrFields: {\n\t\t\t\t// This is important. We need the session cookie to access the LIST in the back-end\n\t\t\t\twithCredentials: true,\n\t\t\t},\n\t\t\tdata: requestData,\n\t\t\tdataType: 'json',\n\t\t} ).success( ( data ) => {\n\t\t\t//New nonce for the next request.\n\t\t\tdispatch.setOnPaymentDeclinedNonce( data.nonce );\n\t\t\tresolve( data );\n\t\t} ).catch( ( e ) => {\n\t\t\tconsole.log( e );\n\t\t\treject( e )\n\t\t} );\n\t} );\n}\n","/*\n * Since the WebSDK is not yet available on npm, we asynchronously\n * load the UMD version from the appropriate env whenever the SDK is initialized\n * for the first time.\n */\n\nconst formatUmdUrl = ( env, sdkVersion ) => {\n\t/**\n\t * When the configuration does not provide a pinned version we can omit the script version to\n\t * load the latest version of the SDK.\n\t *\n\t * @type {string}\n\t */\n\tconst scriptVersion = sdkVersion ? `-${sdkVersion}` : '';\n\n\treturn new URL(\n\t\twindow.PayoneerData.webSdkUmdUrlTemplate\n\t\t\t?.replace( '<env>', env )\n\t\t\t?.replace( '<version>', scriptVersion )\n\t);\n};\n\nconst sdkLoader = ( config ) => {\n\tif ( window.Payoneer?.CheckoutWeb ) {\n\t\treturn window.Payoneer.CheckoutWeb( config );\n\t}\n\n\treturn new Promise( ( resolve, reject ) => {\n\t\tconst script = document.createElement( 'script' );\n\t\tscript.src = formatUmdUrl( config.env, config.sdkVersion );\n\t\tscript.onload = resolve;\n\t\tscript.onerror = reject;\n\n\t\t/**\n\t\t * Add Subresource Integrity (SRI) validation when a specific SDK version is requested.\n\t\t * This enhances security by ensuring the loaded script matches its expected content,\n\t\t * which is a requirement for PCI compliance.\n\t\t */\n\t\tif ( config.sdkVersion && config.sdkIntegrity ) {\n\t\t\tscript.integrity = config.sdkIntegrity;\n\n\t\t\t// Add crossorigin attribute when using integrity checks.\n\t\t\t// This is required for SRI to work properly with CORS.\n\t\t\tscript.crossOrigin = 'anonymous';\n\t\t}\n\t\tdocument.head.appendChild( script );\n\t} ).then( () => {\n\t\treturn window.Payoneer.CheckoutWeb( config );\n\t} );\n};\n\nexport default sdkLoader;\n","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"apiFetch\"];","import { ACTIONS } from \"./constants\";\nimport initializeSdk from \"../util/sdk/umdLoader\";\nimport apiFetch from '@wordpress/api-fetch';\nimport { defaultHooks } from \"@wordpress/hooks\";\n\nconst {\n\twebsdkStyles: styles\n} = PayoneerData;\n\nexport const getSdk = () => async ( { resolveSelect, dispatch } ) => {\n\tconst env = await resolveSelect.getEnv();\n\tconst sdkVersion = await resolveSelect.getSdkVersion();\n\tconst sdkIntegrity = await resolveSelect.getSdkIntegrity();\n\tconst longId = await resolveSelect.getLongId();\n\tconst onBeforeError = async ( sdk, component, data ) => await dispatch.onBeforeError( sdk, component, data );\n\tconst onPaymentDeclined = async ( sdk, component, data ) => await dispatch.onPaymentDeclined( sdk, component, data );\n\tconst onComponentListChange = async ( sdk, changeInfo ) => await dispatch.onComponentListChange( sdk, changeInfo );\n\tconst onValidationInfo = async ( sdk, componentName, data ) => await dispatch.onValidationInfo( sdk, componentName, data );\n\n\tconst sdk = await initializeSdk( {\n\t\tenv,\n\t\tsdkVersion,\n\t\tsdkIntegrity,\n\t\tonBeforeError,\n\t\tonPaymentDeclined,\n\t\tonComponentListChange,\n\t\tonValidationInfo,\n\t\tpreload: [ 'cards' ],\n\t\tstyles\n\t} );\n\n\tif ( sdk.state === 'LOADING' ) {\n\t\tconst nonLoadingState = async () => {\n\t\t\treturn await new Promise( resolve => {\n\t\t\t\tconst interval = setInterval( () => {\n\t\t\t\t\tif ( sdk.state !== 'LOADING' ) {\n\t\t\t\t\t\tresolve( sdk.state );\n\t\t\t\t\t\tclearInterval( interval );\n\t\t\t\t\t}\n\t\t\t\t}, 1000 );\n\t\t\t} );\n\t\t};\n\t\tawait nonLoadingState();\n\t}\n\tawait sdk.updateLongId( longId );\n\tawait dispatch.setForceHostedFlow( false );\n\tawait dispatch.setSdkState( sdk.state );\n\tawait dispatch( { type: ACTIONS.SET_SDK, payload: sdk } );\n}\n/**\n * Perform a Store API call to the cart endpoint where we provide LIST longId and environment\n */\nexport const getExtensionData = () => async ( { dispatch } ) => {\n\n\tconst response = await apiFetch( {\n\t\t/**\n\t\t * /wc/store/v1/cart\n\t\t * is pre-warmed in PHP, so the first API call will always get data produced during\n\t\t * the initial page load.\n\t\t * Here we MUST receive the results of an actual API call.\n\t\t * So we use a custom URL hash to prevent this from happening.\n\t\t */\n\t\tpath: '/wc/store/v1/cart#skipPreloadingMiddleware',\n\t\tmethod: 'GET',\n\t\tcache: 'no-store',\n\t\tparse: false,\n\t} );\n\tconst json = await response.json();\n\tconst payoneerExtensionData = json.extensions[ 'payoneer-checkout' ];\n\tconsole.log('Payoneer Extension Data: ', payoneerExtensionData);\n\tawait dispatch( { type: ACTIONS.SET_EXTENSION_DATA, payload: payoneerExtensionData } );\n\tdefaultHooks.doAction( 'payoneer.checkout.onReceiveExtensionData', payoneerExtensionData )\n}\nexport const getLongId = () => async ( { resolveSelect,dispatch } ) => {\n\tconst extensionData = await resolveSelect.getExtensionData();\n\tawait dispatch( { type: ACTIONS.SET_LONG_ID, payload: extensionData.longId } );\n}\n\nexport const getEnv = () => async ( { resolveSelect,dispatch } ) => {\n\tconst extensionData = await resolveSelect.getExtensionData();\n\tawait dispatch( { type: ACTIONS.SET_ENV, payload: extensionData.environment } );\n}\n\nexport const getSdkVersion = () => async ( { resolveSelect,dispatch } ) => {\n\tconst extensionData = await resolveSelect.getExtensionData();\n\tawait dispatch( { type: ACTIONS.SET_SDK_VERSION, payload: extensionData.sdkVersion } );\n}\n\nexport const getSdkIntegrity = () => async ( { resolveSelect,dispatch } ) => {\n\tconst extensionData = await resolveSelect.getExtensionData();\n\tawait dispatch( { type: ACTIONS.SET_SDK_INTEGRITY, payload: extensionData.sdkIntegrity } );\n}\n","import { createReduxStore, register } from '@wordpress/data';\nimport reducer from './reducer';\nimport * as actions from './actions';\nimport * as resolvers from './resolvers';\nimport selectors from './selectors';\n\nexport const PAYONEER_STORE_KEY = 'payoneer-checkout';\n\nexport const payoneerStore = createReduxStore(PAYONEER_STORE_KEY, {\n\treducer,\n\tactions,\n\tselectors,\n\tresolvers\n});\n\nregister(payoneerStore);\n\n","\nconst selectors = {\n\t/**\n\t * This is technically only needed temporarily to lazy-fetch longId and env\n\t * in a resolver. Maybe there are better ways to deal with this?\n\t */\n\tgetExtensionData: (state) => state.extension,\n\tgetLongId: (state) => state.longId,\n\tgetEnv: (state) => state.env,\n\tgetSdkVersion: (state) => state.sdkVersion,\n\tgetSdkIntegrity: (state) => state.sdkIntegrity,\n\tgetSdk: (state) => state.sdk,\n\tisHostedModeForced: (state) => state.forceHostedFlow,\n\t/**\n\t * Validity only makes sense for Cards payment method\n\t * https://checkoutdocs.payoneer.com/docs/payment-button#listening-for-validation-events\n\t */\n\tgetIsValid: (state) =>\n\t\tstate.activePaymentMethod !== 'payoneer-checkout' ||\n\t\tstate.isValid,\n\tgetActivePaymentMethod: (state) => state.activePaymentMethod,\n\tgetAvailableDropInComponents: (state) => state.availableDropInComponents,\n\tgetOrderId: (state) => state.orderId,\n\tgetOnPaymentDeclinedNonce: (state) => state.onPaymentDeclinedNonce,\n};\n\nexport default selectors;\n","import { PAYONEER_STORE_KEY } from \"../store/index\";\nimport { select } from '@wordpress/data';\nimport { isPayForOrder } from \"./woocommerce\";\nimport { defaultHooks } from \"@wordpress/hooks\";\n\nconst FORCE_HOSTED_MODE_HEADER = 'x-payoneer-checkout-force-hosted-flow'\nconst LIST_LONG_ID = 'x-payoneer-long-id'\nconst IS_PAYMENT_CHECKOUT = 'x-payoneer-is-payment-checkout'\n\nconst paymentCheckoutHeaderValue = () => {\n\tif ( !isPayForOrder ) {\n\t\treturn '' // to avoid receiving random variables from non-payment pages\n\t}\n\tconst urlParams = new URLSearchParams( window.location.search );\n\treturn urlParams.get( 'key' ) || '';\n};\n\nconst getCustomHeaders = () => {\n\tconst customHeaders = {\n\t\t[ FORCE_HOSTED_MODE_HEADER ]: String( select( PAYONEER_STORE_KEY ).isHostedModeForced() ),\n\t\t[ IS_PAYMENT_CHECKOUT ]: paymentCheckoutHeaderValue()\n\t};\n\treturn defaultHooks.applyFilters( 'payoneer.http.customHeaders', customHeaders );\n};\n\n/**\n * Since we need the getLongId resolver to have run once, we defer adding the header\n */\ndefaultHooks.addAction(\n\t'payoneer.checkout.onReceiveExtensionData',\n\t'payoneer/setupCustomHttpHeaders',\n\t() => {\n\t\tdefaultHooks.addFilter(\n\t\t\t'payoneer.http.customHeaders',\n\t\t\t'payoneer/setupCustomHttpHeaders',\n\t\t\tfunction ( headers ) {\n\t\t\t\theaders[ LIST_LONG_ID ] = String( select( PAYONEER_STORE_KEY ).getLongId() )\n\t\t\t\treturn headers;\n\t\t\t}\n\t\t)\n\t} );\n\n/**\n * We decorate the global fetch function so that we can pass custom headers for outgoing requests.\n * This is used to control the hosted mode fallback in the back-end and for validating\n * that the frontend LIST longId matches the one used by the backend\n */\nexport const setupCustomHttpHeaders = async () => {\n\n\tconst originalFetch = window.fetch;\n\n\twindow.fetch = async ( ...args ) => {\n\t\tlet [ url, options ] = args;\n\t\t// Only process requests going out to the same origin\n\t\tif ( new URL( url, window.location.origin ).origin !== window.location.origin ) {\n\t\t\treturn originalFetch( url, options );\n\t\t}\n\t\tconst customHeaders = getCustomHeaders();\n\t\tconsole.log( 'Adding custom headers to fetch call', customHeaders );\n\t\t// Clone the original options to avoid mutating it\n\t\tif ( options && options.headers ) {\n\t\t\toptions = { ...options, headers: { ...options.headers, ...customHeaders } };\n\t\t} else {\n\t\t\toptions = { ...options, headers: customHeaders };\n\t\t}\n\n\t\treturn await originalFetch( url, options );\n\t};\n\n\tif ( !window.XMLHttpRequest ) {\n\t\treturn;\n\t}\n\n\tconst originalOpen = XMLHttpRequest.prototype.open;\n\tconst originalSend = XMLHttpRequest.prototype.send;\n\n\tXMLHttpRequest.prototype.open = function ( method, url, ...rest ) {\n\t\tthis._isSameOrigin = new URL( url, window.location.origin ).origin === window.location.origin;\n\t\toriginalOpen.apply( this, [ method, url, ...rest ] );\n\t};\n\n\tXMLHttpRequest.prototype.send = function ( ...args ) {\n\t\tconst customHeaders = getCustomHeaders();\n\n\t\tif ( this._isSameOrigin ) {\n\t\t\tconsole.log( 'Adding custom headers to XMLHttpRequest call', customHeaders );\n\t\t\tfor ( const [ header, value ] of Object.entries( customHeaders ) ) {\n\t\t\t\tthis.setRequestHeader( header, value );\n\t\t\t}\n\t\t}\n\t\toriginalSend.apply( this, args );\n\t};\n}\n","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wc\"][\"wcBlocksData\"];","import { dispatch } from '@wordpress/data';\nimport { PAYMENT_STORE_KEY } from '@woocommerce/block-data';\nimport { PAYONEER_STORE_KEY } from \"./index\";\nimport { select, subscribe } from '@wordpress/data';\nimport { paymentMethodName } from \"../util/woocommerce\";\n\nexport const setUpBlockCheckoutListeners = () => {\n\n\tlet currentPaymentMethod;\n\n\tconst wcPaymentStore = select( PAYMENT_STORE_KEY );\n\tconst paymentStoreCallback = () => {\n\t\tconst paymentMethod = wcPaymentStore.getActivePaymentMethod();\n\t\tif ( currentPaymentMethod !== paymentMethod ) {\n\t\t\tdispatch( PAYONEER_STORE_KEY ).setActivePaymentMethod( paymentMethod );\n\t\t\tcurrentPaymentMethod = paymentMethod;\n\t\t}\n\t}\n\tconst unsubscribePaymentStore = subscribe( paymentStoreCallback, PAYMENT_STORE_KEY );\n\tpaymentStoreCallback()\n\n\treturn { unsubscribePaymentStore };\n}\n\nexport const setupClassicCheckoutListeners = () => {\n\tconst paymentMethodCallback = function () {\n\t\tconst methodName = paymentMethodName()\n\t\tdispatch( PAYONEER_STORE_KEY ).setActivePaymentMethod( methodName );\n\t}\n\tjQuery( document.body ).on( 'payment_method_selected', paymentMethodCallback );\n\tpaymentMethodCallback()\n}\n\n\n","import { useEffect } from 'react';\nimport { getComponentNameByGatewayId } from \"../../util/components\";\nimport { dispatch } from '@wordpress/data'\nimport { PAYONEER_STORE_KEY } from \"../../store/index\";\n/**\n * @see https://developer.woocommerce.com/2022/10/06/how-the-checkout-block-processes-an-order/\n * @see https://developer.woocommerce.com/docs/cart-and-checkout-payment-method-integration-for-the-checkout-block/#3-props-fed-to-payment-method-nodes\n */\nexport const Component = function (\n\t{\n\t\tpayWithPayoneer,\n\t\tinitPayoneerComponents,\n\t\tpaymentMethodData,\n\t\trebootPayoneer,\n\t\tactivePaymentMethod,\n\t\teventRegistration,\n\t\tisValid\n\t}\n) {\n\n\tconst { onPaymentSetup, onCheckoutSuccess, onCheckoutFail } = eventRegistration;\n\t/**\n\t * Ping the SDK when we see the light of day\n\t */\n\tuseEffect( () => {\n\t\tinitPayoneerComponents()\n\t}, [] )\n\n\tuseEffect( () => {\n\t\treturn onCheckoutSuccess( ({orderId}) => {\n\t\t\tdispatch(PAYONEER_STORE_KEY).setOrderId(orderId);\n\t\t\tpayWithPayoneer();\n\t\t} );\n\t}, [] );\n\n\tuseEffect( () => {\n\t\treturn onCheckoutFail( rebootPayoneer );\n\t}, [] );\n\t/**\n\t * Enhance the payment data validation step.\n\t * We need to validate that the LIST used in block checkout submit\n\t * matches the one we will use for finalizing the transaction in the backend.\n\t * Therefore, we pass additional metadata in this listener\n\t */\n\tuseEffect( () => {\n\t\treturn onPaymentSetup( () => {\n\t\t\treturn isValid\n\t\t\t\t?\n\t\t\t\t{\n\t\t\t\t\ttype: 'success',\n\t\t\t\t}\n\t\t\t\t:\n\t\t\t\t{\n\t\t\t\t\ttype: 'failure',\n\t\t\t\t\tmessage: 'Invalid payment fields',\n\t\t\t\t}\n\t\t} );\n\t}, [ isValid, onPaymentSetup, paymentMethodData ] );\n\n\tconst componentName = getComponentNameByGatewayId( activePaymentMethod );\n\n\treturn <div\n\t\tclassName={`payment_method_${activePaymentMethod}`}\n\t\tdata-component={componentName}\n\t></div>;\n}\n","import { PAYONEER_STORE_KEY } from \"../../store\";\nimport { dispatch, withSelect } from '@wordpress/data';\n\nconst initPayoneerComponents = () => dispatch( PAYONEER_STORE_KEY ).initPayoneerComponents();\nconst payWithPayoneer = () => dispatch( PAYONEER_STORE_KEY ).pay();\nconst rebootPayoneer = () => dispatch( PAYONEER_STORE_KEY ).reboot();\n\n/**\n * Higher-Order Component that maps the inner component's props to our payoneer store\n */\nexport const provider = withSelect(\n\t( select, ownProps ) => {\n\t\tconst payoneer = select( PAYONEER_STORE_KEY )\n\t\tconst {\n\t\t\tactivePaymentMethod,\n\t\t\teventRegistration\n\t\t} = ownProps\n\t\treturn {\n\t\t\tactivePaymentMethod,\n\t\t\teventRegistration,\n\t\t\tpayWithPayoneer,\n\t\t\tinitPayoneerComponents,\n\t\t\trebootPayoneer,\n\t\t\tisValid: payoneer.getIsValid()\n\t\t}\n\t}\n)\n","import {Component} from './component'\nimport {provider} from './provider'\n\nexport const WidgetContainer = provider(Component)\n","import { setUpBlockCheckoutListeners } from \"../../store/storeListeners\";\nimport {WidgetContainer} from '../../components/widgetContainer';\nimport {select, dispatch} from '@wordpress/data';\nimport { PAYONEER_STORE_KEY } from \"../../store/index\";\nimport $ from 'jquery';\nimport { getLongId } from \"../../store/resolvers\";\n\nconst payoneerStore = select( PAYONEER_STORE_KEY );\n\nconst setUpGatewayContainers = function () {\n\tif ( !Array.isArray( inpsydeGateways ) ) {\n\t\tconsole.error('window.inpsydeGateways not found')\n\t\treturn;\n\t}\n\n\tinpsydeGateways.forEach( ( gatewayName ) => {\n\t\taddWidgetContainer( gatewayName );\n\t} );\n};\n\nconst addWidgetContainer = function ( gatewayId ) {\n\twp.hooks.addFilter( `${gatewayId}_checkout_fields`, gatewayId, ( components ) => {\n\t\tcomponents.push(\n\t\t\tWidgetContainer\n\t\t);\n\t\treturn components;\n\t} );\n\n\twp.hooks.addFilter(\n\t\t'payoneer-checkout_payment_method_icons',\n\t\t'payoneer-checkout',\n\t\t(icons) => {\n\t\t\tconst activePaymentMethod = payoneerStore.getActivePaymentMethod();\n\t\t\treturn activePaymentMethod === 'payoneer-checkout' ? [] : icons\n\t\t}\n\t);\n};\n\nconst registerPageReloadingOnPaymentDeclined = () => {\n\tdocument.addEventListener(\n\t\t'DOMContentLoaded',\n\t\t() => {\n\t\t\twp.hooks.addFilter(\n\t\t\t\t'payoneer.webSdk.onPaymentDeclined',\n\t\t\t\t'payoneer/blockCheckout',\n\t\t\t\t() => {\n\t\t\t\t\twp.data.dispatch(PAYONEER_STORE_KEY).releaseOnHoldOrder(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlongId: select( PAYONEER_STORE_KEY ).getLongId(),\n\t\t\t\t\t\t\tpayoneerOrderId: select(PAYONEER_STORE_KEY).getOrderId()\n\t\t\t\t\t\t},\n\t\t\t\t\t);\n\t\t\t\t\t/**\n\t\t\t\t\t * The following is an extreme solution where a correct solution seemingly does not exist.\n\t\t\t\t\t * As of 02/2025, the WooCommerce checkout entirely depends on a redirectUrl after onCheckoutSuccess().\n\t\t\t\t\t * If there is no redirect, core WC will simply do nothing, leaving a nonfunctional checkout page\n\t\t\t\t\t * with a greyed-out blocked Pay button.\n\t\t\t\t\t * You can test this by out-commenting the payment call in our 'onCheckoutSuccess' observer.\n\t\t\t\t\t *\n\t\t\t\t\t * Now:\n\t\t\t\t\t * Our WC backend cannot dictate a redirectUrl because we will only start the client-side CHARGE\n\t\t\t\t\t * after creating the order in the backend. Thus, the backend only finalizes LIST data.\n\t\t\t\t\t * It is the job of the WebSDK to carry out the payment and handle the redirects.\n\t\t\t\t\t * On the happy path, this is not an issue.\n\t\t\t\t\t *\n\t\t\t\t\t * But what if there is an error?\n\t\t\t\t\t * component.pay() is async, but onCheckoutSuccess() can only be influenced synchronously, by returning\n\t\t\t\t\t * success/failure. But we cannot know that since we are not omniscient time-bending 4D creatures yet.\n\t\t\t\t\t *\n\t\t\t\t\t * So since we cannot give WC any meaningful signal before resolving the async call,\n\t\t\t\t\t * we are forced to accept its default behaviour: redirecting to 'redirectUrl' which is empty,\n\t\t\t\t\t * leading to the aforementioned blocked checkout state.\n\t\t\t\t\t *\n\t\t\t\t\t * The only known recovery is dispatch(CHECKOUT_STORE_KEY).__internalSetIdle()\n\t\t\t\t\t * However, that's using an internal function that might be unsafe and could be removed any time.\n\t\t\t\t\t *\n\t\t\t\t\t * So we're picking the heavy tools when they are required. Hints and PRs welcome.\n\t\t\t\t\t *\n\t\t\t\t\t * @see https://developer.woocommerce.com/docs/cart-and-checkout-checkout-flow-and-events/\n\t\t\t\t\t */\n\t\t\t\t\twindow.location.reload();\n\t\t\t\t\treturn true // just out of spite\n\t\t\t\t}\n\t\t\t);\n\t\t},\n\t\tfalse\n\t);\n}\n\nexport const initBlockCheckout = () => {\n\tconsole.log('Loading classic checkout integration')\n\tsetUpBlockCheckoutListeners();\n\tsetUpGatewayContainers();\n\tregisterPageReloadingOnPaymentDeclined();\n}\n","import { isBlockCheckout, isPayForOrder } from './src/util/woocommerce';\nimport { setupCustomHttpHeaders } from './src/util/http';\nimport { initClassicCheckout } from \"./src/util/checkout/classicCheckout\";\nimport { initBlockCheckout } from \"./src/util/checkout/blockCheckout\";\nimport { initPaymentCheckout } from \"./src/util/checkout/paymentCheckout\";\n\n\ndocument.addEventListener(\n\t'DOMContentLoaded',\n\tsetupCustomHttpHeaders,\n\tfalse\n);\n/**\n * Boot one of the supported checkout integrations.\n * Let us hope this list is getting shorter, not longer\n */\nif ( isPayForOrder() ) {\n\tinitPaymentCheckout()\n} else if ( isBlockCheckout() ) {\n\tinitBlockCheckout();\n} else {\n\tinitClassicCheckout()\n}\n\n","import { setupClassicCheckoutListeners } from \"../../store/storeListeners\";\nimport $ from \"jquery\";\nimport {\n\tisPayForOrder,\n\tisPayoneerGatewaySelected,\n\tsubmitOrderPayViaAjax,\n\tfocusOnSelectedGateway\n} from \"../woocommerce\";\nimport { PAYONEER_STORE_KEY } from \"../../store\";\nimport { defaultHooks } from '@wordpress/hooks';\nimport { select, dispatch } from '@wordpress/data';\nimport { releaseOnHoldOrder, setOnPaymentDeclinedNonce } from \"../../store/actions\";\n\n\nexport const initPaymentCheckout = () => {\n\tconsole.log('Loading payment checkout integration')\n\n\tdocument.addEventListener(\n\t\t'DOMContentLoaded',\n\t\t() => {\n\t\t\tsetupClassicCheckoutListeners()\n\t\t\tdispatch(PAYONEER_STORE_KEY).\n\t\t\t\tsetOnPaymentDeclinedNonce(PayoneerData.onPaymentDeclinedNonce);\n\n\t\t\tconst $orderReviewForm = $( '#order_review' );\n\n\t\t\tdefaultHooks.addFilter(\n\t\t\t\t'payoneer.webSdk.onSdkError',\n\t\t\t\t'payoneer/paymentCheckout',\n\t\t\t\t( isResolved, checkout, component, data ) => {\n\t\t\t\t\tconst { payOrderErrorFlag } = window.PayoneerData;\n\t\t\t\t\tconst url = new URL( document.location );\n\t\t\t\t\turl.searchParams.set( payOrderErrorFlag, true );\n\t\t\t\t\twindow.location.href = url.toString();\n\t\t\t\t\treturn isResolved;\n\t\t\t\t}\n\t\t\t);\n\n\t\t\twp.hooks.addFilter(\n\t\t\t\t'payoneer.webSdk.onPaymentDeclined',\n\t\t\t\t'payoneer/paymentCheckout',\n\t\t\t\tasync () => {\n\t\t\t\t\tawait wp.data.dispatch(PAYONEER_STORE_KEY).releaseOnHoldOrder(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlongId: select( PAYONEER_STORE_KEY ).getLongId(),\n\t\t\t\t\t\t\torderKey: new URLSearchParams(window.location.search).get('key'),\n\t\t\t\t\t\t},\n\t\t\t\t\t);\n\t\t\t\t\twindow.location.reload();\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t);\n\n\t\t\t$orderReviewForm.on( 'submit', ( e ) => {\n\t\t\t\tif ( !isPayoneerGatewaySelected() || select( PAYONEER_STORE_KEY ).isHostedModeForced() ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\te.preventDefault();\n\t\t\t\te.stopImmediatePropagation();\n\n\t\t\t\tconst isValid = select( PAYONEER_STORE_KEY ).getIsValid();\n\n\t\t\t\tif ( !isValid ) {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tfocusOnSelectedGateway();\n\t\t\t\t\t} catch (error){\n\t\t\t\t\t\tconsole.error(error);\n\t\t\t\t\t} finally {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t\tsubmitOrderPayViaAjax( $orderReviewForm )\n\t\t\t\t\t.then( () => dispatch( PAYONEER_STORE_KEY ).pay() )\n\t\t\t\t\t.catch( () => {\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * Reloading enables us to see error messages added via wc_add_notice()\n\t\t\t\t\t\t * Scrolling up makes sure the notices are in the viewport after the refresh\n\t\t\t\t\t\t */\n\t\t\t\t\t\twindow.scrollTo( 0, 0 );\n\t\t\t\t\t\twindow.location.reload();\n\t\t\t\t\t} );\n\t\t\t} );\n\n\t\t\tdispatch( PAYONEER_STORE_KEY ).mountComponents();\n\t\t},\n\t\tfalse\n\t);\n}\n","import { setupClassicCheckoutListeners } from \"../../store/storeListeners\";\nimport $ from \"jquery\";\nimport {\n\tgetSelectedPaymentBox,\n\tisPayoneerGatewaySelected,\n\tfocusOnSelectedGateway\n} from \"../woocommerce\";\nimport { PAYONEER_STORE_KEY } from \"../../store\";\nimport { defaultHooks } from '@wordpress/hooks';\nimport { select, dispatch } from '@wordpress/data';\nimport { releaseOnHoldOrder, setOnPaymentDeclinedNonce } from \"../../store/actions\";\n\nexport const initClassicCheckout = () => {\n\tconsole.log('Loading classic checkout integration')\n\tdocument.addEventListener(\n\t\t'DOMContentLoaded',\n\t\t() => {\n\t\t\tsetupClassicCheckoutListeners()\n\t\t\tdispatch(PAYONEER_STORE_KEY)\n\t\t\t\t.setOnPaymentDeclinedNonce(PayoneerData.onPaymentDeclinedNonce);\n\n\t\t\tconst $checkoutForm = $( 'form.checkout' );\n\n\t\t\tdefaultHooks.addFilter(\n\t\t\t\t'payoneer.webSdk.onSdkError',\n\t\t\t\t'payoneer/shortcodeCheckout',\n\t\t\t\t( isResolved, checkout, component, data ) => {\n\t\t\t\t\twp.data.dispatch(PAYONEER_STORE_KEY).reboot();\n\n\t\t\t\t\t$( document.body ).trigger( 'update_checkout' );\n\t\t\t\t\treturn isResolved\n\t\t\t\t}\n\t\t\t);\n\n\t\t\twp.hooks.addFilter(\n\t\t\t\t'payoneer.webSdk.onPaymentDeclined',\n\t\t\t\t'payoneer/shortcodeCheckout',\n\t\t\t\t() => {\n\t\t\t\t\twp.data.dispatch(PAYONEER_STORE_KEY).releaseOnHoldOrder(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlongId: select( PAYONEER_STORE_KEY ).getLongId(),\n\t\t\t\t\t\t},\n\t\t\t\t\t);\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t);\n\n\t\t\t/**\n\t\t\t * Cannot use native event listener for events dispatched by jQuery\n\t\t\t * https://github.com/jquery/jquery/issues/3347\n\t\t\t */\n\t\t\t$( document.body ).on( 'updated_checkout', () => dispatch( PAYONEER_STORE_KEY ).initPayoneerComponents() );\n\n\t\t\t$checkoutForm.on('checkout_place_order', () => {\n\t\t\t\tconst isValid = select( PAYONEER_STORE_KEY ).getIsValid();\n\t\t\t\tif ( isValid ) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tfocusOnSelectedGateway();\n\t\t\t\t} catch(error) {\n\t\t\t\t\tconsole.error(error);\n\t\t\t\t} finally {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t} );\n\n\t\t\t$checkoutForm.on( 'checkout_place_order_success', ( e, result ) => {\n\t\t\t\tif ( !isPayoneerGatewaySelected() || select( PAYONEER_STORE_KEY ).isHostedModeForced() ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tdispatch( PAYONEER_STORE_KEY ).pay();\n\n\t\t\t\t//Override default redirect to hosted payment page\n\t\t\t\tresult.redirect = '#payoneer-redirect';\n\n\t\t\t\t/**\n\t\t\t\t * Create a timeout that races the SDK's payment handling.\n\t\t\t\t * If the handling is not done after 1,5 second, it unblocks\n\t\t\t\t * the checkout form and scrolls the users to the payment fields\n\t\t\t\t * because probably there is an error displayed there\n\t\t\t\t *\n\t\t\t\t * This is done since the SDK does not have any validation callback\n\t\t\t\t * or Promise we could attach to.\n\t\t\t\t */\n\t\t\t\tsetTimeout( () => {\n\t\t\t\t\t$checkoutForm.removeClass( 'processing' ).unblock();\n\t\t\t\t\t$.scroll_to_notices(\n\t\t\t\t\t\t$( getSelectedPaymentBox() )\n\t\t\t\t\t);\n\t\t\t\t}, 1500 );\n\n\t\t\t\treturn false;\n\t\t\t} );\n\t\t},\n\t\tfalse\n\t);\n}\n"],"names":["f","k","Symbol","for","m","Object","prototype","hasOwnProperty","n","__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED","ReactCurrentOwner","p","key","ref","__self","__source","exports","jsx","c","a","g","b","d","e","h","call","defaultProps","$$typeof","type","props","_owner","current","module","window","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","__webpack_modules__","getter","__esModule","definition","o","defineProperty","enumerable","get","obj","prop","r","toStringTag","value","paymentFieldsComponentAttribute","PayoneerData","selectedPaymentGateway","document","querySelector","selectedPaymentGatewayId","id","isPayoneerGatewaySelected","isPayoneerGateway","gatewayId","test","isPayForOrder","focusOnSelectedGateway","focus","ACTIONS","SET_EXTENSION_DATA","SET_LONG_ID","SET_LIST_URL","SET_ENV","SET_SDK","SET_SDK_VERSION","SET_SDK_INTEGRITY","SET_SDK_STATE","ADD_COMPONENT","REMOVE_COMPONENT","MOUNT_COMPONENTS","PAY","SET_ACTIVE_PAYMENT_METHOD","SET_FORCE_HOSTED_FLOW","SET_IS_VALID","SET_ORDER_ID","SET_ON_PAYMENT_DECLINED_NONCE","initialState","activePaymentMethod","longId","env","sdkState","forceHostedFlow","isValid","availableDropInComponents","getComponentNameByGatewayId","mountComponents","components","sdk","componentName","component","entries","container","findComponentContainer","Element","isAvailable","mount","setLongId","async","select","resolveSelect","dispatch","getSdk","updateLongId","payload","setSdkState","setEnv","addComponent","console","log","isDroppedIn","name","dropIn","hidePaymentButton","doMountComponents","error","removeComponent","initPayoneerComponents","getLongId","reboot","defaultHooks","doAction","wp","data","invalidateResolutionForStore","availableComponents","getAvailableDropInComponents","pay","getActivePaymentMethod","onBeforeError","state","includes","interaction","reason","setForceHostedFlow","applyFilters","onPaymentDeclined","onComponentListChange","changeInfo","addedComponents","forEach","removedComponents","onValidationInfo","setIsValid","valid","setActivePaymentMethod","method","flag","setOnPaymentDeclinedNonce","nonce","setOrderId","orderId","releaseOnHoldOrder","requestData","targetUrlBase","wc_checkout_params","wc_ajax_url","toString","replace","separator","targetUrl","onPaymentDeclinedNonce","Promise","resolve","reject","$","url","xhrFields","withCredentials","dataType","success","catch","websdkStyles","styles","getEnv","sdkVersion","getSdkVersion","sdkIntegrity","getSdkIntegrity","config","preload","Payoneer","CheckoutWeb","script","createElement","src","formatUmdUrl","scriptVersion","URL","webSdkUmdUrlTemplate","onload","onerror","integrity","crossOrigin","head","appendChild","then","nonLoadingState","interval","setInterval","clearInterval","getExtensionData","response","apiFetch","path","cache","parse","payoneerExtensionData","json","extensions","extensionData","environment","PAYONEER_STORE_KEY","payoneerStore","createReduxStore","reducer","action","extension","listUrl","actions","selectors","isHostedModeForced","getIsValid","getOrderId","getOnPaymentDeclinedNonce","resolvers","register","FORCE_HOSTED_MODE_HEADER","IS_PAYMENT_CHECKOUT","getCustomHeaders","customHeaders","String","URLSearchParams","location","search","addAction","addFilter","headers","setupClassicCheckoutListeners","paymentMethodCallback","methodName","_document$querySelect","paymentMethodName","jQuery","body","on","payWithPayoneer","rebootPayoneer","WidgetContainer","withSelect","ownProps","payoneer","eventRegistration","provider","paymentMethodData","onPaymentSetup","onCheckoutSuccess","onCheckoutFail","useEffect","message","_jsx","className","addEventListener","originalFetch","fetch","args","options","origin","XMLHttpRequest","originalOpen","open","originalSend","send","rest","this","_isSameOrigin","apply","header","setRequestHeader","$orderReviewForm","isResolved","checkout","payOrderErrorFlag","searchParams","set","href","hooks","orderKey","reload","preventDefault","stopImmediatePropagation","$form","block","overlayCSS","background","opacity","ajax_url","fields","serialize","params","always","unblock","scrollTo","isBlockCheckout","setUpBlockCheckoutListeners","currentPaymentMethod","wcPaymentStore","PAYMENT_STORE_KEY","paymentStoreCallback","paymentMethod","subscribe","Array","isArray","inpsydeGateways","gatewayName","push","icons","payoneerOrderId","$checkoutForm","trigger","result","redirect","setTimeout","removeClass","selector","getPaymentBox"],"sourceRoot":""}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-embedded-payment/src/EmbeddedPaymentModule.php

    r3305047 r3321269  
    1414use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\EmbeddedPayment\AjaxOrderPay\AjaxPayAction;
    1515use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\EmbeddedPayment\AjaxOrderPay\OrderPayload;
    16 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\CheckoutContext;
    1716use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionManager;
    1817use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
     
    107106        $onBeforeServerError = filter_input(\INPUT_GET, $onBeforeServerErrorFlag, \FILTER_CALLBACK, ['options' => 'sanitize_text_field']);
    108107        if ($onBeforeServerError) {
    109             $listSessionManager->persist(null, new PaymentContext($order));
    110108            /**
    111109             * Safely redirect without the $onBeforeServerError flag.
     
    117115            return;
    118116        }
    119         $listSessionManager->persist(null, new CheckoutContext());
    120         $listSessionManager->persist(null, new PaymentContext($order));
    121117        if (!in_array($interactionCode, ['RETRY', 'ABORT'], \true)) {
    122118            return;
     
    176172            woocommerce_store_api_register_endpoint_data(['endpoint' => CartSchema::IDENTIFIER, 'namespace' => 'payoneer-checkout', 'data_callback' => function () use ($container): array {
    177173                return $this->provideCartExtensionData($container);
    178             }, 'schema_callback' => fn() => ['longId' => ['description' => 'LongId of the LIST session', 'type' => 'string', 'readonly' => \true], 'environment' => ['description' => 'The current environment', 'type' => 'string', 'readonly' => \true], 'sdkVersion' => ['description' => 'Pinned WebSDK script version', 'type' => 'string', 'readonly' => \true], 'sdkIntegrity' => ['description' => 'WebSDK integrity hash', 'type' => 'string', 'readonly' => \true]], 'schema_type' => \ARRAY_A]);
     174            }, 'schema_callback' => fn() => ['longId' => ['description' => 'LongId of the LIST session', 'type' => 'string', 'readonly' => \true], 'environment' => ['description' => 'The current environment', 'type' => 'string', 'readonly' => \true], 'sdkVersion' => ['description' => 'Pinned WebSDK script version', 'type' => 'string', 'readonly' => \true], 'sdkIntegrity' => ['description' => 'WebSDK integrity hash', 'type' => 'string', 'readonly' => \true], 'comment' => ['description' => 'Arbitrary text with debugging info, error description, etc.', 'type' => 'string', 'readonly' => \true]], 'schema_type' => \ARRAY_A]);
    179175        });
    180176    }
     
    196192         */
    197193        $isStoreApi = $container->get('wc.is_store_api_request');
     194        $emptyResponse = ['longId' => null, 'environment' => null, 'sdkVersion' => null, 'sdkIntegrity' => null];
    198195        if (!$isStoreApi) {
    199             return ['longId' => null, 'environment' => null, 'sdkVersion' => null, 'sdkIntegrity' => null];
     196            $emptyResponse['comment'] = 'Current request is not Store REST API request';
     197            return $emptyResponse;
    200198        }
    201199        $listProvider = $container->get('list_session.manager');
     
    203201        $envExtractor = $container->get('embedded_payment.list_url_environment_extractor');
    204202        assert($envExtractor instanceof ListUrlEnvironmentExtractor);
    205         $list = $listProvider->provide(ListSessionManager::determineContextFromGlobals());
     203        try {
     204            $list = $listProvider->provide(new PaymentContext());
     205        } catch (\Throwable $throwable) {
     206            $emptyResponse['comment'] = 'Cannot get List, throwable caught: ' . $throwable->getMessage();
     207            return $emptyResponse;
     208        }
    206209        // TODO: Refactor the environment detection to use the current WP options.
    207210        // Extract the environment name from the LIST response.
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-embedded-payment/src/EnvironmentProvider.php

    r3260742 r3321269  
    44namespace Syde\Vendor\Inpsyde\PayoneerForWoocommerce\EmbeddedPayment;
    55
    6 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionManager;
    76use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
     7use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
    88use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ListSession\ListInterface;
    99class EnvironmentProvider
     
    2323    protected function getList(): ListInterface
    2424    {
    25         $context = ListSessionManager::determineContextFromGlobals();
    26         return $this->listSessionProvider->provide($context);
     25        return $this->listSessionProvider->provide(new PaymentContext());
    2726    }
    2827    protected function getListLongId(): string
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-embedded-payment/src/ListLongIdPaymentRequestValidator.php

    r3260742 r3321269  
    77use Syde\Vendor\Inpsyde\PaymentGateway\PaymentRequestValidatorInterface;
    88use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\RequestHeaderUtil;
    9 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\CheckoutContext;
    109use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
     10use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
    1111/**
    1212 * Validates payment requests by checking the presence and value of a custom header.
     
    6262        }
    6363        $headerValue = $headerUtil->getHeader($longIdHeader);
    64         $currentLongId = $this->listSessionProvider->provide(new CheckoutContext())->getIdentification()->getLongId();
     64        $currentLongId = $this->listSessionProvider->provide(new PaymentContext())->getIdentification()->getLongId();
    6565        if ($headerValue !== $currentLongId) {
    6666            throw new \UnexpectedValueException(
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-embedded-payment/src/PaymentFieldsRenderer/ListDebugFieldRenderer.php

    r3111876 r3321269  
    55
    66use Syde\Vendor\Inpsyde\PaymentGateway\PaymentFieldsRendererInterface;
    7 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionManager;
    87use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
     8use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
    99use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ListSession\ListSerializerInterface;
    1010class ListDebugFieldRenderer implements PaymentFieldsRendererInterface
     
    2525    public function renderFields(): string
    2626    {
    27         $context = ListSessionManager::determineContextFromGlobals();
    28         $listSession = $this->listSessionProvider->provide($context);
     27        $listSession = $this->listSessionProvider->provide(new PaymentContext());
    2928        $json = (string) json_encode($this->serializer->serializeListSession($listSession), \JSON_PRETTY_PRINT);
    3029        return '<pre>' . $json . '</pre>';
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-embedded-payment/src/PaymentProcessor/EmbeddedPaymentProcessor.php

    r3305047 r3321269  
    88use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\MisconfigurationDetector\MisconfigurationDetectorInterface;
    99use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\PaymentProcessor\AbstractPaymentProcessor;
    10 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionManager;
    11 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionPersistor;
    1210use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
    1311use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
     
    2523     * @var string
    2624     */
    27     protected $hostedModeOverrideFlag;
     25    protected string $hostedModeOverrideFlag;
    2826    protected bool $isRestRequest;
    29     public function __construct(WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory, ListSessionProvider $sessionProvider, ListSessionPersistor $sessionPersistor, TokenGeneratorInterface $tokenGenerator, string $tokenKey, string $transactionIdFieldName, string $hostedModeOverrideFlag, MisconfigurationDetectorInterface $misconfigurationDetector, string $checkoutSessionHashKey, bool $isRestRequest)
     27    public function __construct(WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory, ListSessionProvider $sessionProvider, TokenGeneratorInterface $tokenGenerator, string $tokenKey, string $transactionIdFieldName, string $hostedModeOverrideFlag, MisconfigurationDetectorInterface $misconfigurationDetector, string $checkoutSessionHashKey, bool $isRestRequest)
    3028    {
    31         parent::__construct($misconfigurationDetector, $sessionProvider, $sessionPersistor, $updateCommandFactory, $tokenGenerator, $tokenKey, $transactionIdFieldName, $checkoutSessionHashKey);
     29        parent::__construct($misconfigurationDetector, $sessionProvider, $updateCommandFactory, $tokenGenerator, $tokenKey, $transactionIdFieldName, $checkoutSessionHashKey);
    3230        $this->hostedModeOverrideFlag = $hostedModeOverrideFlag;
    3331        $this->isRestRequest = $isRestRequest;
     
    3533    public function processPayment(WC_Order $order, PaymentGateway $gateway): array
    3634    {
    37         /**
    38          * Transfer the checkout-based LIST to the WC_Order.
    39          * From there, the parent AbstractPaymentProcessor can take over.
    40          */
    41         $list = $this->sessionProvider->provide(ListSessionManager::determineContextFromGlobals($order));
    42         $this->sessionPersistor->persist($list, new PaymentContext($order));
     35        $this->sessionProvider->provide(new PaymentContext($order));
    4336        try {
    4437            $result = parent::processPayment($order, $gateway);
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-hosted-payment/inc/extensions.php

    r3111876 r3321269  
    3232         */
    3333        $factory = new Factory(['list_session.manager', 'inpsyde_payment_gateway.transaction_id_field_name', 'hosted_payment.misconfiguration_detector', 'hosted_payment.order_based_update_command_factory', 'checkout.security_token_generator', 'checkout.order.security_header_field_name', 'hosted_payment.payment_flow_override_flag.is_set', 'checkout.session_hash_key'], static function (ListSessionManager $listSessionManager, string $transactionIdFieldName, MisconfigurationDetectorInterface $misconfigurationDetector, WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory, TokenGeneratorInterface $tokenGenerator, string $tokenKey, bool $fallbackToHostedModeFlag, string $sessionHashKey): PaymentProcessorInterface {
    34             return new HostedPaymentProcessor($listSessionManager, $transactionIdFieldName, $misconfigurationDetector, $listSessionManager, $updateCommandFactory, $tokenGenerator, $tokenKey, $fallbackToHostedModeFlag, $sessionHashKey);
     34            return new HostedPaymentProcessor($transactionIdFieldName, $misconfigurationDetector, $listSessionManager, $updateCommandFactory, $tokenGenerator, $tokenKey, $fallbackToHostedModeFlag, $sessionHashKey);
    3535        });
    3636        return $factory($container);
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-hosted-payment/src/PaymentProcessor/HostedPaymentProcessor.php

    r3305047 r3321269  
    77use Syde\Vendor\Inpsyde\PaymentGateway\PaymentGateway;
    88use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\Authentication\TokenGeneratorInterface;
    9 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\CheckoutExceptionInterface;
    109use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\MisconfigurationDetector\MisconfigurationDetectorInterface;
    1110use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\PaymentProcessor\AbstractPaymentProcessor;
    12 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionPersistor;
    1311use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
    1412use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
     
    2523{
    2624    /**
    27      * @var ListSessionPersistor
    28      */
    29     protected $listSessionPersistor;
    30     /**
    3125     * @var bool
    3226     */
    33     protected $fallbackToHostedModeFlag;
    34     public function __construct(ListSessionPersistor $listSessionPersistor, string $transactionIdFieldName, MisconfigurationDetectorInterface $misconfigurationDetector, ListSessionProvider $sessionProvider, WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory, TokenGeneratorInterface $tokenGenerator, string $tokenKey, bool $fallbackToHostedModeFlag, string $checkoutSessionHashKey)
     27    protected bool $fallbackToHostedModeFlag;
     28    public function __construct(string $transactionIdFieldName, MisconfigurationDetectorInterface $misconfigurationDetector, ListSessionProvider $sessionProvider, WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory, TokenGeneratorInterface $tokenGenerator, string $tokenKey, bool $fallbackToHostedModeFlag, string $checkoutSessionHashKey)
    3529    {
    36         parent::__construct($misconfigurationDetector, $sessionProvider, $listSessionPersistor, $updateCommandFactory, $tokenGenerator, $tokenKey, $transactionIdFieldName, $checkoutSessionHashKey);
    37         $this->listSessionPersistor = $listSessionPersistor;
     30        parent::__construct($misconfigurationDetector, $sessionProvider, $updateCommandFactory, $tokenGenerator, $tokenKey, $transactionIdFieldName, $checkoutSessionHashKey);
    3831        $this->fallbackToHostedModeFlag = $fallbackToHostedModeFlag;
    3932    }
     
    4336    public function processPayment(WC_Order $order, PaymentGateway $gateway): array
    4437    {
    45         $this->clearOutdatedListInOrder($order);
    4638        /**
    4739         * Here we create a new List if failed to update existing one.
     
    9183    }
    9284    /**
    93      * If fallback to HPP flag is set, we need to clear saved LIST. It may be created for embedded
    94      * flow, so we cannot use it.
    95      *
    96      * @param WC_Order $order
    97      *
    98      * @throws CheckoutExceptionInterface
    99      */
    100     protected function clearOutdatedListInOrder(WC_Order $order): void
    101     {
    102         if ($this->fallbackToHostedModeFlag) {
    103             $this->listSessionPersistor->persist(null, new PaymentContext($order));
    104         }
    105     }
    106     /**
    10785     * If the LIST response contains a redirect object, craft a compatible URL
    10886     * out of the given URL and its parameters. If none is found, use our own return URL
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/inc/extensions.php

    r3305047 r3321269  
    66use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Factory\RedirectInjectingListFactory;
    77use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ListSession\ListFactoryInterface;
    8 use Syde\Vendor\Psr\Container\ContainerInterface;
    98return static function (): array {
    109    return ['payoneer_sdk.list_factory' => static function (ListFactoryInterface $previous): ListFactoryInterface {
    1110        return new RedirectInjectingListFactory($previous);
    12     }, 'list_session.middlewares' => static function (array $middlewares, ContainerInterface $container): array {
    13         if ($container->get('wc.session.is-available')) {
    14             /**
    15              * If WC_Session is available, we want respective middleware to be present.
    16              * Even if we will be unable to create list (i.e. cart is not yet initialized),
    17              * we want to be able to get saved List session from WC_Session.
    18              */
    19             \array_unshift($middlewares, $container->get('list_session.middlewares.wc-session'));
    20         }
    21         /**
    22          * If it is safe to boot a LIST,
    23          * we can add additional middleware relevant to the frontend UX
    24          */
    25         if (!$container->get('list_session.can_try_create_list')) {
    26             return $middlewares;
    27         }
    28         /**
    29          * The order is important here!
    30          */
    31         \array_unshift($middlewares, $container->get('list_session.middlewares.wc-session-update'));
    32         /**
    33          * Prepend the validating middleware as the last step.
    34          * We do not want anything to execute before it.
    35          */
    36         \array_unshift($middlewares, $container->get('list_session.middlewares.validating'));
    37         return $middlewares;
    3811    }];
    3912};
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/inc/factories.php

    r3305047 r3321269  
    44namespace Syde\Vendor;
    55
     6use Syde\Vendor\Dhii\Services\Factory;
    67use Syde\Vendor\Psr\Container\ContainerInterface;
    78return static function (): array {
     
    3637        },
    3738        'list_session.can_try_create_list' => static fn(ContainerInterface $container) => $container->get('list_session.can_persist') && $container->get('list_session.can_create'),
     39        'wc.order_under_payment' => new Factory(['wc.order_awaiting_payment', 'wc.pay_for_order_id'], static function (int $orderAwaitingPayment, int $payForOrderId): int {
     40            if ($payForOrderId) {
     41                return $payForOrderId;
     42            }
     43            return $orderAwaitingPayment;
     44        }),
     45        'wc.pay_for_order_id' => new Factory(['wc.pay_for_order_id.from_header', 'wc'], static function (int $orderIdFromHeader): int {
     46            $orderPay = \get_query_var('order-pay');
     47            if (\is_numeric($orderPay) && (int) $orderPay > 0) {
     48                return (int) $orderPay;
     49            }
     50            return $orderIdFromHeader;
     51        }),
    3852    ];
    3953};
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/inc/services.php

    r3305047 r3321269  
    2121use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ApiListSessionProvider;
    2222use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionManager;
    23 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionManagerProxy;
    24 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\NoopListSessionPersistor;
     23use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Middleware\ListCache;
    2524use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Middleware\UpdatingMiddleware;
    26 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Middleware\ValidatingMiddleware;
    27 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Middleware\WcOrderMiddleware;
    28 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Middleware\WcSessionMiddleware;
     25use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Middleware\FetchingMiddleware;
    2926use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Api\Gateway\WcProductSerializer\WcProductSerializerInterface;
    3027use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Callback\CallbackFactoryInterface;
     
    6663            return 'v5';
    6764        },
    68         'list_session.default_persistor' => new Constructor(NoopListSessionPersistor::class, []),
    69         'list_session.creator' => new Constructor(ApiListSessionProvider::class, ['list_session.list_session_factory', 'list_session.order_based_list_session_factory', 'list_session.integration_type', 'list_session.can_try_create_list', 'list_session.hosted_version']),
    70         'list_session.middlewares.validating' => new Constructor(ValidatingMiddleware::class, ['payoneer_sdk.commands.fetch', 'list_session.manager.proxy']),
    71         'list_session.middlewares.wc-order' => new Constructor(WcOrderMiddleware::class, ['checkout.order_list_session_field_name', 'core.list_serializer', 'core.list_deserializer']),
    72         'list_session.middlewares.wc-session' => new Constructor(WcSessionMiddleware::class, ['wc.session', 'checkout.list_session_manager.cache_key', 'core.list_serializer', 'core.list_deserializer']),
    73         'list_session.middlewares.wc-session-update' => new Constructor(UpdatingMiddleware::class, ['list_session.manager.proxy', 'list_session.list_session_factory', 'checkout.checkout_hash_provider', 'checkout.session_hash_key', 'core.order_based_update_command_factory', 'wp.is_rest_api_request']),
    74         'list_session.middlewares' => new ServiceList([
    75             /**
    76              * WcOrderMiddleware only operates on PaymentContext, otherwise just calls next
    77              * middleware. PaymentContext always contains order, so it is safe to always have
    78              * WcOrderMiddleware.
    79              *
    80              * @todo: consider doing the same with the WC_Session List provider
    81              */
    82             'list_session.middlewares.wc-order',
    83             'list_session.creator',
    84             'list_session.default_persistor',
    85         ]),
     65        'list_session.creator' => new Constructor(ApiListSessionProvider::class, ['list_session.list_session_factory', 'list_session.order_based_list_session_factory', 'list_session.integration_type', 'list_session.can_try_create_list.callable', 'list_session.hosted_version']),
     66        'list_session.list_cache' => new Constructor(ListCache::class),
     67        'list_session.middlewares.fetching' => new Constructor(FetchingMiddleware::class, ['payoneer_sdk.commands.fetch', 'list_session.list_cache', 'list_session.selected_payment_flow']),
     68        'list_session.middlewares.wc-session-update' => new Constructor(UpdatingMiddleware::class, ['list_session.list_session_factory', 'checkout.checkout_hash_provider', 'checkout.session_hash_key', 'core.order_based_update_command_factory', 'wp.is_rest_api_request', 'list_session.list_cache']),
     69        'list_session.middlewares' => new ServiceList(['list_session.middlewares.wc-session-update', 'list_session.middlewares.fetching', 'list_session.creator']),
    8670        'list_session.manager' => new Constructor(ListSessionManager::class, ['list_session.middlewares']),
    8771        /**
    88          * An unpleasant helper to break a recursive dependency chain.
     72         * Callback returning can_try_create_list value.
    8973         *
     74         * Since this value may change during the request processing (note this is factories,
     75         * not services), we want to have the actual value in the class, not the one saved
     76         * as a class property when it was created.
    9077         */
    91         'list_session.manager.proxy' => static function (ContainerInterface $container): ListSessionManagerProxy {
    92             /**
    93              * @return ListSessionManager
    94              * @var callable():ListSessionManager $factory
    95              */
    96             $factory = static function () use ($container): ListSessionManager {
    97                 /**
    98                  * @var ListSessionManager $manager
    99                  */
    100                 $manager = $container->get('list_session.manager');
    101                 return $manager;
    102             };
    103             return new ListSessionManagerProxy($factory);
    104         },
     78        'list_session.can_try_create_list.callable' => static fn(ContainerInterface $container) => static fn() => $container->get('list_session.can_try_create_list'),
    10579    ];
    10680};
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/src/Factory/RedirectInjectingListFactory.php

    r3111876 r3321269  
    1111use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Network\NetworksInterface;
    1212use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Payment\PaymentInterface;
    13 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelInterface;
    1413use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Redirect\RedirectInterface;
    1514use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Status\StatusInterface;
     
    2827     * @inheritDoc
    2928     */
    30     public function createList(array $links, IdentificationInterface $identification, StatusInterface $status, PaymentInterface $payment = null, CustomerInterface $customer = null, StyleInterface $style = null, RedirectInterface $redirect = null, string $division = null, array $products = null, ProcessingModelInterface $processingModel = null, NetworksInterface $networks = null): ListInterface
     29    public function createList(array $links, IdentificationInterface $identification, StatusInterface $status, PaymentInterface $payment = null, CustomerInterface $customer = null, StyleInterface $style = null, RedirectInterface $redirect = null, string $division = null, array $products = null, NetworksInterface $networks = null): ListInterface
    3130    {
    3231        $redirect = $redirect ?? apply_filters('payoneer-checkout.fallback_redirect', $redirect, $identification);
     
    3433            throw new ApiException('Redirect must be instance of RedirectInterface or null');
    3534        }
    36         return $this->listFactory->createList($links, $identification, $status, $payment, $customer, $style, $redirect, $division, $products, $processingModel, $networks);
     35        return $this->listFactory->createList($links, $identification, $status, $payment, $customer, $style, $redirect, $division, $products, $networks);
    3736    }
    3837}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/src/ListSession/ApiListSessionProvider.php

    r3305047 r3321269  
    44namespace Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession;
    55
     6use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Factory\FactoryExceptionInterface;
    67use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Factory\ListSession\OrderBasedListSessionFactory;
    78use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Factory\ListSession\WcBasedListSessionFactoryInterface;
     
    1314     * @var WcBasedListSessionFactoryInterface
    1415     */
    15     private $checkoutFactory;
     16    private WcBasedListSessionFactoryInterface $checkoutFactory;
    1617    /**
    1718     * @var OrderBasedListSessionFactory
    1819     */
    19     private $listFactory;
     20    private OrderBasedListSessionFactory $listFactory;
    2021    /**
    2122     * @var PayoneerIntegrationTypes::* $integrationType
     
    2324    private $integrationType;
    2425    /**
    25      * @var bool
     26     * @var callable
    2627     */
    27     private bool $canCreateList;
     28    private $canCreateList;
    2829    /**
    2930     * @var string|null
    3031     */
    31     private $hostedVersion;
     32    private ?string $hostedVersion;
    3233    /**
    3334     * @param WcBasedListSessionFactoryInterface $checkoutFactory
    3435     * @param OrderBasedListSessionFactory $listFactory
    3536     * @param string $integrationType $integrationType
    36      * @param bool $canCreateList
     37     * @param callable $canCreateList
    3738     * @param string|null $hostedVersion
    3839     *
    3940     * @psalm-param PayoneerIntegrationTypes::* $integrationType
    4041     */
    41     public function __construct(WcBasedListSessionFactoryInterface $checkoutFactory, OrderBasedListSessionFactory $listFactory, string $integrationType, bool $canCreateList, string $hostedVersion = null)
     42    public function __construct(WcBasedListSessionFactoryInterface $checkoutFactory, OrderBasedListSessionFactory $listFactory, string $integrationType, callable $canCreateList, string $hostedVersion = null)
    4243    {
    4344        $this->checkoutFactory = $checkoutFactory;
     
    4748        $this->canCreateList = $canCreateList;
    4849    }
     50    /**
     51     * @throws FactoryExceptionInterface
     52     */
    4953    public function provide(ContextInterface $context): ListInterface
    5054    {
    51         if (!$this->canCreateList) {
     55        if (!($this->canCreateList)()) {
    5256            throw new \RuntimeException('Cannot create List session.');
    5357        }
    54         if ($context instanceof CheckoutContext) {
    55             $totals = $context->getCart()->get_total('edit');
     58        $order = $context->getOrder();
     59        $cart = $context->getCart();
     60        $customer = $context->getCustomer();
     61        if ($order === null) {
     62            if ($cart === null) {
     63                throw new \RuntimeException(sprintf('Cart not found for customer session in %s', __CLASS__));
     64            }
     65            if ($customer === null) {
     66                throw new \RuntimeException(sprintf('WC Customer not found in %s', __CLASS__));
     67            }
     68            $totals = $cart->get_total('edit');
    5669            if (!$totals) {
    5770                throw new \RuntimeException(sprintf('Invalid totals amount in %s', __CLASS__));
    5871            }
    59             $list = $this->checkoutFactory->createList($context->getCustomer(), $context->getCart(), $this->integrationType, $this->hostedVersion);
    60             $context->offsetSet('list_just_created', \true);
     72            $list = $this->checkoutFactory->createList($customer, $cart, $this->integrationType, $this->hostedVersion);
     73            $context->offsetSet('pristine', \true);
    6174            return $list;
    6275        }
    63         if ($context instanceof PaymentContext) {
    64             $list = $this->listFactory->createList($context->getOrder(), $this->integrationType, $this->hostedVersion);
    65             $context->offsetSet('list_just_created', \true);
    66             return $list;
    67         }
    68         throw new \RuntimeException(sprintf('Unknown Context passed to %s', __CLASS__));
     76        $list = $this->listFactory->createList($order, $this->integrationType, $this->hostedVersion);
     77        $context->offsetSet('pristine', \true);
     78        return $list;
    6979    }
    7080}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/src/ListSession/ContextInterface.php

    r3080398 r3321269  
    55interface ContextInterface extends \ArrayAccess
    66{
     7    public function getCart(): ?\WC_Cart;
     8    public function getCustomer(): ?\WC_Customer;
     9    public function getSession(): ?\WC_Session;
     10    public function getOrder(): ?\WC_Order;
    711}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionManager.php

    r3260742 r3321269  
    44namespace Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession;
    55
    6 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\RequestHeaderUtil;
    76use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ListSession\ListInterface;
    8 class ListSessionManager implements ListSessionProvider, ListSessionPersistor
     7class ListSessionManager implements ListSessionProvider
    98{
    109    /**
    11      * @var ListSessionMiddleware[]|ListSessionProvider[]|ListSessionPersistor[]
     10     * @var ListSessionMiddleware[]|ListSessionProvider[]
    1211     */
    1312    private $middlewares;
    1413    /**
    15      * @param ListSessionMiddleware[]|ListSessionProvider[]|ListSessionPersistor[] $middlewares
     14     * @param ListSessionMiddleware[]|ListSessionProvider[] $middlewares
    1615     */
    1716    public function __construct(array $middlewares)
    1817    {
    1918        $this->middlewares = $middlewares;
    20     }
    21     public function persist(?ListInterface $list, ContextInterface $context): bool
    22     {
    23         reset($this->middlewares);
    24         $runner = new Runner($this->middlewares);
    25         return $runner->persist($list, $context);
    2619    }
    2720    public function provide(ContextInterface $context): ListInterface
     
    3124        return $runner->provide($context);
    3225    }
    33     /**
    34      * Decide whether to use PaymentContext (order-based) or CheckoutContext (cart-based)
    35      * by inspecting request data.
    36      *
    37      * TODO: turn this global method into a service so that we can use proper dependencies from our container
    38      *
    39      * @param \WC_Order|null $order
    40      *
    41      * @return ContextInterface
    42      */
    43     public static function determineContextFromGlobals(\WC_Order $order = null): ContextInterface
    44     {
    45         /**
    46          * When using the Store API we currently rely on custom HHT header to pass information
    47          * about the current checkout attempt.
    48          */
    49         $headerUtil = new RequestHeaderUtil();
    50         $paymentCheckoutHeader = 'x-payoneer-is-payment-checkout';
    51         $orderKey = $headerUtil->getHeader($paymentCheckoutHeader);
    52         if (!empty($orderKey)) {
    53             $orderId = wc_get_order_id_by_order_key($orderKey);
    54             $order = wc_get_order($orderId);
    55             if ($order instanceof \WC_Order) {
    56                 return new PaymentContext($order);
    57             }
    58         }
    59         /**
    60          * For initial page loads, we can use classic WP/WC functions to inspect the current request
    61          */
    62         if (is_checkout_pay_page() || isset($_POST['action']) && $_POST['action'] === 'payoneer_order_pay') {
    63             if ($order === null) {
    64                 $orderId = get_query_var('order-pay');
    65                 $order = wc_get_order((int) $orderId);
    66             }
    67             // Ensure the order is of type WC_Order
    68             if ($order instanceof \WC_Order) {
    69                 return new PaymentContext($order);
    70             }
    71         }
    72         /**
    73          * When in doubt, return the CheckoutContext which covers classic & block checkout
    74          */
    75         return new CheckoutContext();
    76     }
    7726}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionManagerProxy.php

    r3111876 r3321269  
    55
    66use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ListSession\ListInterface;
    7 class ListSessionManagerProxy implements ListSessionProvider, ListSessionPersistor
     7class ListSessionManagerProxy implements ListSessionProvider
    88{
    99    /**
     
    2727        return $manager;
    2828    }
    29     public function persist(?ListInterface $list, ContextInterface $context): bool
    30     {
    31         return $this->ensureManager()->persist($list, $context);
    32     }
    3329    public function provide(ContextInterface $context): ListInterface
    3430    {
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/src/ListSession/PaymentContext.php

    r3111876 r3321269  
    44namespace Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession;
    55
     6use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\RequestHeaderUtil;
    67/**
    78 * Describes an "order-based" context.
     
    1213class PaymentContext extends AbstractContext
    1314{
    14     /**
    15      * @var \WC_Order
    16      */
    17     private $order;
    18     public function __construct(\WC_Order $order)
     15    private ?\WC_Order $order;
     16    public function __construct(?\WC_Order $order = null)
    1917    {
    2018        $this->order = $order;
    2119    }
    22     public function getOrder(): \WC_Order
     20    public function getCart(): ?\WC_Cart
    2321    {
    24         return $this->order;
     22        return WC()->cart;
     23    }
     24    public function getCustomer(): ?\WC_Customer
     25    {
     26        return WC()->customer;
     27    }
     28    public function getSession(): ?\WC_Session
     29    {
     30        return WC()->session;
     31    }
     32    public function getOrder(): ?\WC_Order
     33    {
     34        if ($this->order) {
     35            return $this->order;
     36        }
     37        /**
     38         * When using the Store API we currently rely on custom HHT header to pass information
     39         * about the current checkout attempt.
     40         */
     41        $headerUtil = new RequestHeaderUtil();
     42        $paymentCheckoutHeader = 'x-payoneer-is-payment-checkout';
     43        $orderKey = $headerUtil->getHeader($paymentCheckoutHeader);
     44        if (!empty($orderKey)) {
     45            $orderId = wc_get_order_id_by_order_key($orderKey);
     46            $order = wc_get_order($orderId);
     47            if ($order instanceof \WC_Order) {
     48                return $order;
     49            }
     50        }
     51        /**
     52         * For initial page loads, we can use classic WP/WC functions to inspect the current request
     53         */
     54        if (is_checkout_pay_page() || isset($_POST['action']) && $_POST['action'] === 'payoneer_order_pay') {
     55            $orderId = get_query_var('order-pay');
     56            $order = wc_get_order((int) $orderId);
     57            // Ensure the order is of type WC_Order
     58            if ($order instanceof \WC_Order) {
     59                return $order;
     60            }
     61        }
     62        return null;
    2563    }
    2664}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/src/ListSession/Runner.php

    r3111876 r3321269  
    66use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ListSession\ListInterface;
    77use RuntimeException;
    8 class Runner implements ListSessionProvider, ListSessionPersistor
     8class Runner implements ListSessionProvider
    99{
    1010    /**
    11      * @var array<ListSessionMiddleware|ListSessionProvider|ListSessionPersistor>
     11     * @var array<ListSessionMiddleware|ListSessionProvider>
    1212     */
    1313    private $middlewares;
    1414    /**
    15      * @param array<ListSessionMiddleware|ListSessionProvider|ListSessionPersistor> $middlewares
     15     * @param array<ListSessionMiddleware|ListSessionProvider> $middlewares
    1616     */
    1717    public function __construct(array $middlewares)
    1818    {
    1919        $this->middlewares = $middlewares;
    20     }
    21     public function persist(?ListInterface $list, ContextInterface $context): bool
    22     {
    23         /** @var ListSessionMiddleware|ListSessionProvider|ListSessionPersistor $middleware */
    24         $middleware = current($this->middlewares);
    25         next($this->middlewares);
    26         /**
    27          * We only process persistor middlewares. So if we have a wrong one,
    28          * skip it by calling the handler again, moving the cursor forward
    29          */
    30         if ($middleware instanceof ListSessionMiddleware && !$middleware instanceof ListSessionPersistorMiddleware) {
    31             return $this->persist($list, $context);
    32         }
    33         /**
    34          * Skip providers as well
    35          */
    36         if ($middleware instanceof ListSessionProvider) {
    37             return $this->persist($list, $context);
    38         }
    39         if ($middleware instanceof ListSessionPersistorMiddleware) {
    40             return $middleware->persist($list, $context, $this);
    41         }
    42         if ($middleware instanceof ListSessionPersistor) {
    43             return $middleware->persist($list, $context);
    44         }
    45         throw new RuntimeException(sprintf('Invalid middleware queue entry: %s. Middleware must either be callable or implement %s.', get_class($middleware), ListSessionPersistorMiddleware::class));
    4620    }
    4721    public function provide(ContextInterface $context): ListInterface
     
    5933            return $this->provide($context);
    6034        }
    61         /**
    62          * Skip persistors as well
    63          */
    64         if ($middleware instanceof ListSessionPersistor) {
    65             return $this->provide($context);
    66         }
    6735        if ($middleware instanceof ListSessionProviderMiddleware) {
    6836            return $middleware->provide($context, $this);
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-list-session/src/Middleware/UpdatingMiddleware.php

    r3260742 r3321269  
    55
    66use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Api\Gateway\CommandFactory\WcOrderBasedUpdateCommandFactoryInterface;
     7use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\CheckoutExceptionInterface;
    78use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\HashProvider\HashProviderInterface;
    89use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\Factory\ListSession\WcBasedUpdateCommandFactoryInterface;
    9 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\CheckoutContext;
    1010use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ContextInterface;
    11 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionPersistor;
    1211use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
    1312use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProviderMiddleware;
    14 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
     13use Syde\Vendor\Inpsyde\PayoneerSdk\Api\ApiExceptionInterface;
     14use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Command\Exception\CommandExceptionInterface;
    1515use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Command\UpdateListCommandInterface;
    1616use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ListSession\ListInterface;
    1717class UpdatingMiddleware implements ListSessionProviderMiddleware
    1818{
     19    use IsProcessingTrait;
    1920    protected bool $isRestRequest;
    20     /**
    21      * @var ListSessionPersistor
    22      */
    23     private $persistor;
    2421    /**
    2522     * @var WcBasedUpdateCommandFactoryInterface
    2623     */
    2724    protected $wcBasedListSessionFactory;
     25    private ListCacheInterface $listCache;
    2826    /**
    2927     * @var HashProviderInterface
     
    3533    private $sessionHashKey;
    3634    protected WcOrderBasedUpdateCommandFactoryInterface $orderBasedUpdateCommandFactory;
    37     public function __construct(ListSessionPersistor $persistor, WcBasedUpdateCommandFactoryInterface $wcBasedListSessionFactory, HashProviderInterface $hashProvider, string $sessionHashKey, WcOrderBasedUpdateCommandFactoryInterface $orderBasedUpdateCommandFactory, bool $isRestRequest)
     35    public function __construct(WcBasedUpdateCommandFactoryInterface $wcBasedListSessionFactory, HashProviderInterface $hashProvider, string $sessionHashKey, WcOrderBasedUpdateCommandFactoryInterface $orderBasedUpdateCommandFactory, bool $isRestRequest, ListCacheInterface $listCache)
    3836    {
    39         $this->persistor = $persistor;
    4037        $this->wcBasedListSessionFactory = $wcBasedListSessionFactory;
    4138        $this->hashProvider = $hashProvider;
     
    4340        $this->orderBasedUpdateCommandFactory = $orderBasedUpdateCommandFactory;
    4441        $this->isRestRequest = $isRestRequest;
     42        $this->listCache = $listCache;
    4543    }
    4644    public function provide(ContextInterface $context, ListSessionProvider $next): ListInterface
    4745    {
     46        $list = $next->provide($context);
     47        $longId = $list->getIdentification()->getLongId();
     48        /**
     49         * We cache here already to avoid multiple UPDATE calls in
     50         * case of recursion.
     51         * After the UPDATE,
     52         * we will cache again to make sure we cache the updated list.
     53         */
     54        $this->listCache->cacheList($list);
    4855        /**
    4956         * If we are already at the payment stage,
    5057         * we will let the gateway deal with final updates
    5158         */
    52         if ($this->isProcessing($context)) {
    53             return $next->provide($context);
     59        if ($this->isProcessing()) {
     60            return $list;
    5461        }
    55         if ($context instanceof PaymentContext) {
    56             return $this->provideForPaymentContext($context, $next);
    57         }
    58         if ($context instanceof CheckoutContext) {
    59             return $this->provideForCheckoutContext($context, $next);
    60         }
    61         //If we ever add a new type of context, we must be handling it properly.
    62         throw new \UnexpectedValueException('Unexpected context type.');
    63     }
    64     /**
    65      * During payment processing, the final UPDATE is carried out by individual PaymentProcessors.
    66      * Therefore, we want to be able to skip redundant UPDATE calls in that stage of the journey.
    67      *
    68      * @param ContextInterface $context
    69      *
    70      * @return bool
    71      */
    72     protected function isProcessing(ContextInterface $context): bool
    73     {
    74         /**
    75          * During the checkout journey, the LIST is transferred from the WC_Session
    76          * to the WC_Order. So we can perform this check for ANY context:
    77          */
    78         if (did_action('woocommerce_before_checkout_process') > 0) {
    79             return \true;
    80         }
    81         /**
    82          * Now check specifically for PaymentContext
    83          */
    84         return $context instanceof PaymentContext && did_action('woocommerce_before_pay_action') > 0;
    85     }
    86     protected function provideForPaymentContext(PaymentContext $context, ListSessionProvider $provider): ListInterface
    87     {
    88         $list = $provider->provide($context);
    89         if ($context->offsetExists('list_just_created')) {
     62        if ($context->offsetExists('pristine')) {
    9063            //It is a fresh list, nothing to do with it.
    9164            return $list;
    9265        }
    9366        try {
    94             $command = $this->orderBasedUpdateCommandFactory->createUpdateCommand($context->getOrder(), $list);
    95             $updatedList = $this->updateList($command, $list);
    96             $this->persistor->persist($updatedList, $context);
    97             return $updatedList;
    98         } catch (\Throwable $throwable) {
    99             $this->persistor->persist(null, $context);
    100             return $provider->provide($context);
     67            $order = $context->getOrder();
     68            if ($order !== null) {
     69                $list = $this->updateBasedOnOrder($list, $order);
     70                $this->listCache->cacheList($list);
     71                return $this->listCache->getCachedListByLongId($longId);
     72            }
     73            $customer = $context->getCustomer();
     74            $session = $context->getSession();
     75            $cart = $context->getCart();
     76            $invoiceId = $list->getPayment()->getInvoiceId();
     77            if ($session !== null && $cart !== null && $customer !== null && substr($invoiceId, 0, 4) === 'inv_') {
     78                $list = $this->updateBasedOnSession($list, $session, $customer, $cart, $context->offsetExists('pristine'));
     79            }
     80        } catch (\Throwable $exception) {
     81            //TODO Log errors during UPDATE
     82            $list = $next->provide($context);
    10183        }
     84        $this->listCache->cacheList($list);
     85        return $this->listCache->getCachedListByLongId($longId);
    10286    }
    103     protected function provideForCheckoutContext(CheckoutContext $context, ListSessionProvider $provider): ListInterface
     87    /**
     88     * @param ListInterface $list
     89     * @param \WC_Order $order
     90     *
     91     * @return ListInterface
     92     * @throws ApiExceptionInterface
     93     * @throws CheckoutExceptionInterface
     94     * @throws CommandExceptionInterface
     95     */
     96    protected function updateBasedOnOrder(ListInterface $list, \WC_Order $order): ListInterface
    10497    {
    105         $list = $provider->provide($context);
     98        $command = $this->orderBasedUpdateCommandFactory->createUpdateCommand($order, $list);
     99        return $this->updateList($command, $list);
     100    }
     101    /**
     102     * @throws \Throwable
     103     */
     104    protected function updateBasedOnSession(ListInterface $list, \WC_Session $session, \WC_Customer $customer, \WC_Cart $cart, bool $pristine): ListInterface
     105    {
    106106        /**
    107107         * We don't want to update List before this hook. It is fired after cart totals is
     
    120120         * We write the current hash to prevent an unneeded update next time the LIST is requested
    121121         */
    122         if ($context->offsetExists('list_just_created')) {
    123             $context->getSession()->set($this->sessionHashKey, $currentHash);
     122        if ($pristine) {
     123            $session->set($this->sessionHashKey, $currentHash);
    124124            return $list;
    125125        }
     
    128128         * If it has not changed, return the existing LIST
    129129         */
    130         $storedHash = $context->getSession()->get($this->sessionHashKey);
     130        $storedHash = $session->get($this->sessionHashKey);
    131131        if ($storedHash === $currentHash) {
    132132            return $list;
    133133        }
    134         try {
    135             $command = $this->wcBasedListSessionFactory->createUpdateCommand($list->getIdentification(), $context->getCustomer(), $context->getCart());
    136             $updated = $this->updateList($command, $list);
    137         } catch (\Throwable $exception) {
    138             /**
    139              * Clear any stored LIST downstream. The existing one is no longer usable
    140              */
    141             $this->persistor->persist(null, $context);
    142             /**
    143              * Re-run the stack.
    144              * With persisted LISTs now cleared, we should get a fresh one from the API
    145              */
    146             return $provider->provide($context);
    147         }
     134        $command = $this->wcBasedListSessionFactory->createUpdateCommand($list->getIdentification(), $customer, $cart);
     135        $updated = $this->updateList($command, $list);
    148136        /**
    149137         * Update checkout hash since the LIST has now changed
    150138         */
    151         $context->getSession()->set($this->sessionHashKey, $currentHash);
    152         /**
    153          * Store the updated LIST
    154          */
    155         $this->persistor->persist($updated, $context);
     139        $session->set($this->sessionHashKey, $currentHash);
    156140        return $updated;
    157141    }
     142    /**
     143     * @throws CommandExceptionInterface
     144     */
    158145    protected function updateList(UpdateListCommandInterface $command, ListInterface $list): ListInterface
    159146    {
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-payment-gateway-checkout/inc/services.php

    r3305047 r3321269  
    7676), 'checkout.settings.general_settings_fields' => Service::fromFile(__DIR__ . "/general_settings_fields.php"), 'checkout.flow_options' => new Value([]), 'checkout.flow_options_description' => static function (): string {
    7777        return __('Select the payment flow for every transaction.', 'payoneer-checkout');
    78     }, 'checkout.payment_flow_override_flag' => new Value('payoneer_force_hosted_flow'), 'checkout.payment_flow_override_flag.is_set' => new Factory(['checkout.payment_flow_override_flag'], static function (string $forceHostedFlowFlag): bool {
     78    }, 'checkout.payment_flow_override_flag' => new Value('payoneer_force_hosted_flow'), 'checkout.payment_flow_override_flag.is_set' => new Factory(['checkout.payment_flow_override_flag', 'wp.is_rest_api_request', 'wc.is_store_api_request'], static function (string $forceHostedFlowFlag, bool $isRestApiRequest, bool $isStoreApiRequest): bool {
     79        if ($isRestApiRequest && !$isStoreApiRequest) {
     80            /**
     81             * This is a REST API request, and it is not from block checkout. Therefore,
     82             * there cannot be payment flow override flag.
     83             */
     84            return \false;
     85        }
    7986        /**
    8087         * Frontend JS decorates fetch() to pass a custom header to all outgoing HTTP calls
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-payment-gateway-checkout/src/CheckoutModule.php

    r3260742 r3321269  
    1010use Syde\Vendor\Inpsyde\Modularity\Module\ServiceModule;
    1111use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\MisconfigurationDetector\MisconfigurationDetectorInterface;
    12 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\CheckoutContext;
    13 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionManager;
    14 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionPersistor;
    15 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
    16 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
    1712use Syde\Vendor\Psr\Container\ContainerInterface;
    1813use RuntimeException;
     
    5550        $this->registerCacheSaltUpdating($container);
    5651        $this->setupFiringPaymentCompleteAction($container);
    57         $this->registerClearingListIfHppFallbackFlagSet($container);
    58         $this->registerClearingListOnFailedOrderPayment($container);
    59         $this->registerMovingListToCreatedOrder($container);
    6052        $this->registerAddingLiveModeNotice($container);
    6153        $notificationReceivedOptionName = (string) $container->get('checkout.notification_received.option_name');
     
    8880    }
    8981    /**
    90      * If forcing hosted payment page flow flag is set, this means we are in the embedded payment
    91      * flow mode, and payment widget wasn't properly set up on the frontend, so we have to switch
    92      * to the HPP mode on the go. Therefore, we need to remove saved LIST session because it was
    93      * created for the embedded flow. The new one will be created automatically.
    94      *
    95      * @param ContainerInterface $container
    96      *
    97      * @return void
    98      */
    99     protected function registerClearingListIfHppFallbackFlagSet(ContainerInterface $container): void
    100     {
    101         add_action(
    102             'woocommerce_checkout_order_processed',
    103             function ($_orderId, $_postedData, $order) use ($container): void {
    104                 if (!$order instanceof WC_Order) {
    105                     return;
    106                 }
    107                 if (!$this->isPayoneerOrderPaymentMethod($container, $order)) {
    108                     return;
    109                 }
    110                 $isForceHppFlagSet = (bool) $container->get('checkout.payment_flow_override_flag.is_set');
    111                 if ($isForceHppFlagSet) {
    112                     $listSessionManager = $container->get('list_session.manager');
    113                     assert($listSessionManager instanceof ListSessionManager);
    114                     $listSessionManager->persist(null, new CheckoutContext());
    115                 }
    116             },
    117             9,
    118             //Clear the List before we will try to move it to the created order
    119             3
    120         );
    121     }
    122     /**
    123      * When the API reports an unrecoverable state during processing, it means the LIST
    124      * session needs to be restarted. Here, we flush the LIST session
    125      * from any context in such an event
    126      *
    127      * @param ContainerInterface $container
    128      *
    129      * @return void
    130      * @throws \Psr\Container\ContainerExceptionInterface
    131      * @throws \Psr\Container\NotFoundExceptionInterface
    132      */
    133     protected function registerClearingListOnFailedOrderPayment(ContainerInterface $container): void
    134     {
    135         add_action(
    136             'payoneer-checkout.payment_processing_failure',
    137             /** @throws CheckoutExceptionInterface */
    138             static function (array $args = null) use ($container) {
    139                 $listRemover = $container->get('list_session.manager');
    140                 assert($listRemover instanceof ListSessionManager);
    141                 /**
    142                  * Flush the LIST from the customer session
    143                  */
    144                 $listRemover->persist(null, new CheckoutContext());
    145                 /**
    146                  * Now check if there was already an order passed as context.
    147                  * If yes, flush it from the order as well
    148                  */
    149                 $order = $args['order'] ?? null;
    150                 if (!$order instanceof WC_Order) {
    151                     return;
    152                 }
    153                 $listRemover->persist(null, new PaymentContext($order));
    154             }
    155         );
    156     }
    157     protected function registerMovingListToCreatedOrder(ContainerInterface $container): void
    158     {
    159         add_action('woocommerce_checkout_order_processed', function (
    160             $_orderId,
    161             //underscore is for psalm to not complain about unused variable
    162             $_postedData,
    163             $order
    164         ) use ($container): void {
    165             if (!$order instanceof WC_Order) {
    166                 return;
    167             }
    168             if (!$this->isPayoneerOrderPaymentMethod($container, $order)) {
    169                 return;
    170             }
    171             $listManager = $container->get('list_session.manager');
    172             assert($listManager instanceof ListSessionPersistor);
    173             assert($listManager instanceof ListSessionProvider);
    174             /**
    175              * This may look weird, but this is what we want to do. We are getting List with
    176              * checkout context and saving it with payment context.
    177              *
    178              * Since this is a transition moment between session and a new order right before
    179              * payment processing, this should be ok.
    180              **/
    181             $list = $listManager->provide(new CheckoutContext());
    182             $listManager->persist($list, new PaymentContext($order));
    183         }, 10, 3);
    184     }
    185     /**
    18682     * We are not in control of the CHARGE call, but we need the CHARGE longId
    18783     * for refunds via webhooks
     
    19692     * @return void
    19793     */
    198     protected function onThankYouPage(WC_Order $order, ListSessionPersistor $listSessionPersistor, string $metaKey)
    199     {
    200         /**
    201          * Prevent re-using the List inside the WC_Session
    202          */
    203         $listSessionPersistor->persist(null, new CheckoutContext());
     94    protected function onThankYouPage(WC_Order $order, string $metaKey)
     95    {
    20496        $chargeLongId = filter_input(\INPUT_GET, 'longId', \FILTER_CALLBACK, ['options' => 'sanitize_text_field']);
    20597        if ($chargeLongId && !$order->meta_exists($metaKey)) {
     
    286178     *
    287179     * @param WC_Order $order
    288      * @param ListSessionPersistor $listSessionPersistor
    289180     *
    290181     * @return void
    291182     */
    292     protected function beforeOrderPay(WC_Order $order, ListSessionPersistor $listSessionPersistor): void
     183    protected function beforeOrderPay(WC_Order $order): void
    293184    {
    294185        $interactionCode = filter_input(\INPUT_GET, 'interactionCode', \FILTER_CALLBACK, ['options' => 'sanitize_text_field']);
     
    323214            $order->save();
    324215        }
    325         if ($interactionCode === 'ABORT') {
    326             $listSessionPersistor->persist(null, new PaymentContext($order));
    327         }
    328216    }
    329217    protected function addCustomerNotice(string $interactionReason): void
     
    359247                return;
    360248            }
    361             $listSessionManager = $container->get('list_session.manager');
    362             assert($listSessionManager instanceof ListSessionManager);
    363             $this->beforeOrderPay($wcOrder, $listSessionManager);
     249            $this->beforeOrderPay($wcOrder);
    364250        }, 0);
    365251        add_action('woocommerce_before_thankyou', function (int $orderId) use ($container) {
     
    373259                return;
    374260            }
    375             $listSessionManager = $container->get('list_session.manager');
    376             assert($listSessionManager instanceof ListSessionManager);
    377261            $chargeIdFieldName = (string) $container->get('inpsyde_payment_gateway.charge_id_field_name');
    378             $this->onThankYouPage($wcOrder, $listSessionManager, $chargeIdFieldName);
     262            $this->onThankYouPage($wcOrder, $chargeIdFieldName);
    379263        });
    380264        /**
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-payment-gateway-checkout/src/PaymentProcessor/AbstractPaymentProcessor.php

    r3305047 r3321269  
    88use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\CheckoutExceptionInterface;
    99use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\MisconfigurationDetector\MisconfigurationDetectorInterface;
    10 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionPersistor;
    1110use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
    1211use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
     
    3130abstract class AbstractPaymentProcessor implements PaymentProcessorInterface
    3231{
    33     /**
    34      * @var MisconfigurationDetectorInterface
    35      */
    36     protected $misconfigurationDetector;
    37     /**
    38      * @var ListSessionProvider
    39      */
    40     protected $sessionProvider;
    41     /**
    42      * @var ListSessionPersistor
    43      */
    44     protected $sessionPersistor;
    45     /**
    46      * @var WcOrderBasedUpdateCommandFactoryInterface
    47      */
    48     protected $updateCommandFactory;
    49     /**
    50      * @var string
    51      */
    52     protected $transactionIdFieldName;
    53     /**
    54      * @var TokenGeneratorInterface
    55      */
    56     private $tokenGenerator;
    57     /**
    58      * @var string
    59      */
    60     private $tokenKey;
     32    protected MisconfigurationDetectorInterface $misconfigurationDetector;
     33    protected ListSessionProvider $sessionProvider;
     34    protected WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory;
     35    protected string $transactionIdFieldName;
     36    private TokenGeneratorInterface $tokenGenerator;
     37    private string $tokenKey;
    6138    private string $sessionHashKey;
    6239    /**
    6340     * @param MisconfigurationDetectorInterface $misconfigurationDetector
    6441     * @param ListSessionProvider $sessionProvider
    65      * @param ListSessionPersistor $sessionPersistor
    6642     * @param WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory
    6743     * @param TokenGeneratorInterface $tokenGenerator
     
    7046     * @param string $sessionHashKey
    7147     */
    72     public function __construct(MisconfigurationDetectorInterface $misconfigurationDetector, ListSessionProvider $sessionProvider, ListSessionPersistor $sessionPersistor, WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory, TokenGeneratorInterface $tokenGenerator, string $tokenKey, string $transactionIdFieldName, string $sessionHashKey)
     48    public function __construct(MisconfigurationDetectorInterface $misconfigurationDetector, ListSessionProvider $sessionProvider, WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory, TokenGeneratorInterface $tokenGenerator, string $tokenKey, string $transactionIdFieldName, string $sessionHashKey)
    7349    {
    7450        $this->misconfigurationDetector = $misconfigurationDetector;
    7551        $this->sessionProvider = $sessionProvider;
    76         $this->sessionPersistor = $sessionPersistor;
    7752        $this->updateCommandFactory = $updateCommandFactory;
    7853        $this->tokenGenerator = $tokenGenerator;
     
    126101    protected function updateOrderWithSessionData(WC_Order $order, ListInterface $list): void
    127102    {
    128         $this->sessionPersistor->persist($list, new PaymentContext($order));
    129103        $identification = $list->getIdentification();
    130104        $transactionId = $identification->getTransactionId();
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-payment-methods/inc/services.php

    r3305047 r3321269  
    145145            return $settingsPageDescription;
    146146        }),
    147         'payment_methods.availability_callback.checkout_predicate' => static function (ContainerInterface $container): callable {
    148             return static function () use ($container): bool {
    149                 return (bool) $container->get('list_session.can_try_create_list');
    150             };
    151         },
     147        //todo: think about moving this to factories
     148        'payment_methods.availability_callback.checkout_predicate' => new Alias('list_session.can_try_create_list.callable'),
    152149        'payment_methods.availability_callback.live_mode' => new Constructor(LiveModeAvailabilityCallback::class, ['payment_methods.is_live_mode', 'wc.admin_permission', 'payment_methods.show_payment_widget_to_customers_in_sandbox_mode']),
    153150        'payment_methods.payoneer-hosted.availability_callback' => new Factory(['payment_methods.availability_callback.live_mode', 'list_session.manager', 'embedded_payment.ajax_order_pay.is_ajax_order_pay', 'payment_methods.availability_callback.checkout_predicate'], static function (AvailabilityCallbackInterface $liveModeCallback, ListSessionManager $listSessionManager, bool $isAjaxOrderPay, callable $checkoutPredicate): AvailabilityCallbackInterface {
     
    182179        'payment_methods.transaction_url_template_field_name' => new Value('_transaction_url_template'),
    183180        'payment_gateway.payoneer-hosted.payment_processor' => new Factory(['list_session.manager', 'payment_methods.order.transaction_id_field_name', 'hosted_payment.misconfiguration_detector', 'hosted_payment.order_based_update_command_factory', 'checkout.security_token_generator', 'checkout.order.security_header_field_name', 'hosted_payment.payment_flow_override_flag.is_set', 'checkout.session_hash_key'], static function (ListSessionManager $listSessionManager, string $transactionIdFieldName, MisconfigurationDetectorInterface $misconfigurationDetector, WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory, TokenGeneratorInterface $tokenGenerator, string $tokenKey, bool $fallbackToHostedModeFlag, string $sessionHashKey): PaymentProcessorInterface {
    184             return new HostedPaymentProcessor($listSessionManager, $transactionIdFieldName, $misconfigurationDetector, $listSessionManager, $updateCommandFactory, $tokenGenerator, $tokenKey, $fallbackToHostedModeFlag, $sessionHashKey);
     181            return new HostedPaymentProcessor($transactionIdFieldName, $misconfigurationDetector, $listSessionManager, $updateCommandFactory, $tokenGenerator, $tokenKey, $fallbackToHostedModeFlag, $sessionHashKey);
    185182        }),
    186183        'payment_gateway.payoneer-checkout.payment_processor' => new Factory(['inpsyde_payoneer_api.update_command_factory', 'list_session.manager', 'payment_methods.order.transaction_id_field_name', 'checkout.payment_flow_override_flag', 'embedded_payment.misconfiguration_detector', 'checkout.security_token_generator', 'checkout.order.security_header_field_name', 'checkout.session_hash_key', 'wp.is_rest_api_request'], static function (WcOrderBasedUpdateCommandFactoryInterface $updateCommandFactory, ListSessionManager $listSessionManager, string $transactionIdFieldName, string $hostedModeOverrideFlag, MisconfigurationDetectorInterface $misconfigurationDetector, TokenGeneratorInterface $tokenGenerator, string $tokenKey, string $sessionHashKey, bool $isRestRequest): PaymentProcessorInterface {
    187             return new EmbeddedPaymentProcessor($updateCommandFactory, $listSessionManager, $listSessionManager, $tokenGenerator, $tokenKey, $transactionIdFieldName, $hostedModeOverrideFlag, $misconfigurationDetector, $sessionHashKey, $isRestRequest);
     184            return new EmbeddedPaymentProcessor($updateCommandFactory, $listSessionManager, $tokenGenerator, $tokenKey, $transactionIdFieldName, $hostedModeOverrideFlag, $misconfigurationDetector, $sessionHashKey, $isRestRequest);
    188185        }),
    189186        'payment_gateway.payoneer-afterpay.payment_processor' => new Alias('payment_gateway.payoneer-checkout.payment_processor'),
    190         'payment_gateway.payoneer-checkout.refund_processor' => new Constructor(RefundProcessor::class, ['inpsyde_payment_gateway.payoneer', 'list_session.manager', 'inpsyde_payment_gateway.payment_factory', 'inpsyde_payment_gateway.charge_id_field_name', 'payment_methods.payout_id_field_name', 'payment_methods.refund_reason_suffix_template', 'payment_gateways']),
     187        'payment_gateway.payoneer-checkout.refund_processor' => new Constructor(RefundProcessor::class, ['inpsyde_payment_gateway.payoneer', 'inpsyde_payment_gateway.transaction_id_field_name', 'inpsyde_payment_gateway.payment_factory', 'inpsyde_payment_gateway.charge_id_field_name', 'payment_methods.payout_id_field_name', 'payment_methods.refund_reason_suffix_template', 'payment_gateways']),
    191188        'payment_gateway.payoneer-hosted.refund_processor' => new Alias('payment_gateway.payoneer-checkout.refund_processor'),
    192189        'payment_gateway.payoneer-afterpay.refund_processor' => new Alias('payment_gateway.payoneer-checkout.refund_processor'),
     
    210207            return new DefaultIconsRenderer($iconProvider);
    211208        }),
    212         'payment_methods.icon_provider_factory' => new Constructor(IconProviderFactory::class, ['core.main_plugin_file', 'payment_methods.path.assets', 'list_session.can_try_create_list', 'list_session.manager', 'payment_methods.network_icon_map']),
     209        'payment_methods.icon_provider_factory' => new Constructor(IconProviderFactory::class, ['core.main_plugin_file', 'payment_methods.path.assets', 'list_session.can_try_create_list.callable', 'list_session.manager', 'payment_methods.network_icon_map']),
    213210        'payment_gateway.payoneer-hosted.method_icon_provider' => new Factory(['payment_methods.icon_provider_factory', 'payment_methods.payoneer-hosted.default_icons'], static function (IconProviderFactory $iconProviderFactory, array $defaultIcons): IconProviderInterface {
    214211            return $iconProviderFactory->create($defaultIcons);
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-payment-methods/src/AvailabilityCallback/ListConditionAvailabilityCallback.php

    r3111876 r3321269  
    66use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\EmbeddedPayment\AjaxOrderPay\OrderPayload;
    77use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionManager;
     8use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
    89use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\PaymentMethods\ListCondition\ListConditionInterface;
    910use WC_Payment_Gateway;
     
    2728                $order = $orderPayload->getOrder();
    2829            }
    29             $listSession = $this->listSessionManager->provide(ListSessionManager::determineContextFromGlobals($order));
     30            $listSession = $this->listSessionManager->provide(new PaymentContext($order));
    3031        } catch (\Throwable $exception) {
    3132            return \false;
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-payment-methods/src/GatewayIconsRenderer/DynamicIconProvider.php

    r3260742 r3321269  
    66use Syde\Vendor\Inpsyde\PaymentGateway\Icon;
    77use Syde\Vendor\Inpsyde\PaymentGateway\IconProviderInterface;
    8 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionManager;
    98use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
     9use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
    1010use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ListSession\ListInterface;
    1111/**
     
    2020{
    2121    protected ListSessionProvider $listSessionProvider;
    22     /** @var array<string, string> $networkMap*/
     22    /** @var array<string, string> $networkMap */
    2323    protected array $networkMap;
    2424    protected IconProviderInterface $default;
     
    7373    private function getList(): ListInterface
    7474    {
    75         return $this->listSessionProvider->provide(ListSessionManager::determineContextFromGlobals());
     75        return $this->listSessionProvider->provide(new PaymentContext());
    7676    }
    7777}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-payment-methods/src/GatewayIconsRenderer/IconProviderFactory.php

    r3305047 r3321269  
    1212    protected string $mainPluginFile;
    1313    protected string $assetPath;
    14     protected bool $canTryCreateList;
     14    /** @var callable */
     15    protected $canTryCreateList;
    1516    protected ListSessionProvider $listSessionProvider;
    1617    /** @var array<string, string> */
     
    1920     * @param array<string, string> $networkMap
    2021     */
    21     public function __construct(string $mainPluginFile, string $assetPath, bool $canTryCreateList, ListSessionProvider $listSessionProvider, array $networkMap)
     22    public function __construct(string $mainPluginFile, string $assetPath, callable $canTryCreateList, ListSessionProvider $listSessionProvider, array $networkMap)
    2223    {
    2324        $this->mainPluginFile = $mainPluginFile;
     
    3637         * If it is safe to boot a LIST, we can inspect real data
    3738         */
    38         if (!$this->canTryCreateList) {
     39        if (!($this->canTryCreateList)()) {
    3940            return $defaultIconProvider;
    4041        }
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-payment-methods/src/RefundProcessor.php

    r3114998 r3321269  
    55
    66use Exception;
    7 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\ListSessionProvider;
    8 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\ListSession\ListSession\PaymentContext;
    97use Syde\Vendor\Inpsyde\PayoneerSdk\Api\ApiExceptionInterface;
    108use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Command\PayoutCommandInterface;
     
    1816class RefundProcessor implements RefundProcessorInterface
    1917{
    20     /**
    21      * @var ListSessionProvider
    22      */
    23     protected $listSessionProvider;
    24     /**
    25      * @var PaymentFactoryInterface
    26      */
    27     protected $paymentFactory;
    28     /**
    29      * @var PayoneerInterface
    30      */
    31     protected $payoneer;
    32     /**
    33      * @var string
    34      */
    35     protected $chargeIdFieldName;
     18    protected string $transactionIdFieldName;
     19    protected PaymentFactoryInterface $paymentFactory;
     20    protected PayoneerInterface $payoneer;
     21    protected string $chargeIdFieldName;
    3622    protected string $payoutIdFieldName;
    3723    protected string $refundReasonSuffixTemplate;
     
    3925    /**
    4026     * @param PayoneerInterface $payoneer
    41      * @param ListSessionProvider $listSessionProvider
     27     * @param string $transactionIdFieldName
    4228     * @param PaymentFactoryInterface $paymentFactory
    4329     * @param string $chargeIdFieldName
     
    4531     * @param string $refundReasonSuffixTemplate
    4632     */
    47     public function __construct(PayoneerInterface $payoneer, ListSessionProvider $listSessionProvider, PaymentFactoryInterface $paymentFactory, string $chargeIdFieldName, string $payoutIdFieldName, string $refundReasonSuffixTemplate, array $payoneerPaymentGatewaysIds)
     33    public function __construct(PayoneerInterface $payoneer, string $transactionIdFieldName, PaymentFactoryInterface $paymentFactory, string $chargeIdFieldName, string $payoutIdFieldName, string $refundReasonSuffixTemplate, array $payoneerPaymentGatewaysIds)
    4834    {
    4935        $this->payoneer = $payoneer;
    50         $this->listSessionProvider = $listSessionProvider;
     36        $this->transactionIdFieldName = $transactionIdFieldName;
    5137        $this->paymentFactory = $paymentFactory;
    5238        $this->chargeIdFieldName = $chargeIdFieldName;
     
    8369    protected function configurePayoutCommand(WC_Order $order, float $amount, string $reason): PayoutCommandInterface
    8470    {
    85         try {
    86             $listSession = $this->listSessionProvider->provide(new PaymentContext($order));
    87         } catch (RuntimeException $exception) {
    88             throw new InvalidArgumentException('Failed to process refund: order has no associated LIST session.', 0, $exception);
    89         }
    90         $transactionId = $listSession->getIdentification()->getTransactionId();
     71        $transactionId = (string) $order->get_meta($this->transactionIdFieldName, \true);
    9172        try {
    9273            $payment = $this->paymentFactory->createPayment($reason, $amount, 0, $amount, $order->get_currency(), $order->get_order_number());
     
    10788     *
    10889     * @return void
     90     * @throws \WC_Data_Exception
    10991     */
    11092    protected function setupSavingPayoutData(string $payoutLongId): void
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/LICENSE

    r2933494 r3321269  
    1 Copyright (c) 2021 Inpsyde GmbH
    2 
    3 Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
    4 
    5 The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
    6 
    7 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
    8 
     1                    GNU GENERAL PUBLIC LICENSE
     2                       Version 2, June 1991
     3
     4 Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
     5 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
     6 Everyone is permitted to copy and distribute verbatim copies
     7 of this license document, but changing it is not allowed.
     8
     9                            Preamble
     10
     11  The licenses for most software are designed to take away your
     12freedom to share and change it.  By contrast, the GNU General Public
     13License is intended to guarantee your freedom to share and change free
     14software--to make sure the software is free for all its users.  This
     15General Public License applies to most of the Free Software
     16Foundation's software and to any other program whose authors commit to
     17using it.  (Some other Free Software Foundation software is covered by
     18the GNU Lesser General Public License instead.)  You can apply it to
     19your programs, too.
     20
     21  When we speak of free software, we are referring to freedom, not
     22price.  Our General Public Licenses are designed to make sure that you
     23have the freedom to distribute copies of free software (and charge for
     24this service if you wish), that you receive source code or can get it
     25if you want it, that you can change the software or use pieces of it
     26in new free programs; and that you know you can do these things.
     27
     28  To protect your rights, we need to make restrictions that forbid
     29anyone to deny you these rights or to ask you to surrender the rights.
     30These restrictions translate to certain responsibilities for you if you
     31distribute copies of the software, or if you modify it.
     32
     33  For example, if you distribute copies of such a program, whether
     34gratis or for a fee, you must give the recipients all the rights that
     35you have.  You must make sure that they, too, receive or can get the
     36source code.  And you must show them these terms so they know their
     37rights.
     38
     39  We protect your rights with two steps: (1) copyright the software, and
     40(2) offer you this license which gives you legal permission to copy,
     41distribute and/or modify the software.
     42
     43  Also, for each author's protection and ours, we want to make certain
     44that everyone understands that there is no warranty for this free
     45software.  If the software is modified by someone else and passed on, we
     46want its recipients to know that what they have is not the original, so
     47that any problems introduced by others will not reflect on the original
     48authors' reputations.
     49
     50  Finally, any free program is threatened constantly by software
     51patents.  We wish to avoid the danger that redistributors of a free
     52program will individually obtain patent licenses, in effect making the
     53program proprietary.  To prevent this, we have made it clear that any
     54patent must be licensed for everyone's free use or not licensed at all.
     55
     56  The precise terms and conditions for copying, distribution and
     57modification follow.
     58
     59                    GNU GENERAL PUBLIC LICENSE
     60   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
     61
     62  0. This License applies to any program or other work which contains
     63a notice placed by the copyright holder saying it may be distributed
     64under the terms of this General Public License.  The "Program", below,
     65refers to any such program or work, and a "work based on the Program"
     66means either the Program or any derivative work under copyright law:
     67that is to say, a work containing the Program or a portion of it,
     68either verbatim or with modifications and/or translated into another
     69language.  (Hereinafter, translation is included without limitation in
     70the term "modification".)  Each licensee is addressed as "you".
     71
     72Activities other than copying, distribution and modification are not
     73covered by this License; they are outside its scope.  The act of
     74running the Program is not restricted, and the output from the Program
     75is covered only if its contents constitute a work based on the
     76Program (independent of having been made by running the Program).
     77Whether that is true depends on what the Program does.
     78
     79  1. You may copy and distribute verbatim copies of the Program's
     80source code as you receive it, in any medium, provided that you
     81conspicuously and appropriately publish on each copy an appropriate
     82copyright notice and disclaimer of warranty; keep intact all the
     83notices that refer to this License and to the absence of any warranty;
     84and give any other recipients of the Program a copy of this License
     85along with the Program.
     86
     87You may charge a fee for the physical act of transferring a copy, and
     88you may at your option offer warranty protection in exchange for a fee.
     89
     90  2. You may modify your copy or copies of the Program or any portion
     91of it, thus forming a work based on the Program, and copy and
     92distribute such modifications or work under the terms of Section 1
     93above, provided that you also meet all of these conditions:
     94
     95    a) You must cause the modified files to carry prominent notices
     96    stating that you changed the files and the date of any change.
     97
     98    b) You must cause any work that you distribute or publish, that in
     99    whole or in part contains or is derived from the Program or any
     100    part thereof, to be licensed as a whole at no charge to all third
     101    parties under the terms of this License.
     102
     103    c) If the modified program normally reads commands interactively
     104    when run, you must cause it, when started running for such
     105    interactive use in the most ordinary way, to print or display an
     106    announcement including an appropriate copyright notice and a
     107    notice that there is no warranty (or else, saying that you provide
     108    a warranty) and that users may redistribute the program under
     109    these conditions, and telling the user how to view a copy of this
     110    License.  (Exception: if the Program itself is interactive but
     111    does not normally print such an announcement, your work based on
     112    the Program is not required to print an announcement.)
     113
     114These requirements apply to the modified work as a whole.  If
     115identifiable sections of that work are not derived from the Program,
     116and can be reasonably considered independent and separate works in
     117themselves, then this License, and its terms, do not apply to those
     118sections when you distribute them as separate works.  But when you
     119distribute the same sections as part of a whole which is a work based
     120on the Program, the distribution of the whole must be on the terms of
     121this License, whose permissions for other licensees extend to the
     122entire whole, and thus to each and every part regardless of who wrote it.
     123
     124Thus, it is not the intent of this section to claim rights or contest
     125your rights to work written entirely by you; rather, the intent is to
     126exercise the right to control the distribution of derivative or
     127collective works based on the Program.
     128
     129In addition, mere aggregation of another work not based on the Program
     130with the Program (or with a work based on the Program) on a volume of
     131a storage or distribution medium does not bring the other work under
     132the scope of this License.
     133
     134  3. You may copy and distribute the Program (or a work based on it,
     135under Section 2) in object code or executable form under the terms of
     136Sections 1 and 2 above provided that you also do one of the following:
     137
     138    a) Accompany it with the complete corresponding machine-readable
     139    source code, which must be distributed under the terms of Sections
     140    1 and 2 above on a medium customarily used for software interchange; or,
     141
     142    b) Accompany it with a written offer, valid for at least three
     143    years, to give any third party, for a charge no more than your
     144    cost of physically performing source distribution, a complete
     145    machine-readable copy of the corresponding source code, to be
     146    distributed under the terms of Sections 1 and 2 above on a medium
     147    customarily used for software interchange; or,
     148
     149    c) Accompany it with the information you received as to the offer
     150    to distribute corresponding source code.  (This alternative is
     151    allowed only for noncommercial distribution and only if you
     152    received the program in object code or executable form with such
     153    an offer, in accord with Subsection b above.)
     154
     155The source code for a work means the preferred form of the work for
     156making modifications to it.  For an executable work, complete source
     157code means all the source code for all modules it contains, plus any
     158associated interface definition files, plus the scripts used to
     159control compilation and installation of the executable.  However, as a
     160special exception, the source code distributed need not include
     161anything that is normally distributed (in either source or binary
     162form) with the major components (compiler, kernel, and so on) of the
     163operating system on which the executable runs, unless that component
     164itself accompanies the executable.
     165
     166If distribution of executable or object code is made by offering
     167access to copy from a designated place, then offering equivalent
     168access to copy the source code from the same place counts as
     169distribution of the source code, even though third parties are not
     170compelled to copy the source along with the object code.
     171
     172  4. You may not copy, modify, sublicense, or distribute the Program
     173except as expressly provided under this License.  Any attempt
     174otherwise to copy, modify, sublicense or distribute the Program is
     175void, and will automatically terminate your rights under this License.
     176However, parties who have received copies, or rights, from you under
     177this License will not have their licenses terminated so long as such
     178parties remain in full compliance.
     179
     180  5. You are not required to accept this License, since you have not
     181signed it.  However, nothing else grants you permission to modify or
     182distribute the Program or its derivative works.  These actions are
     183prohibited by law if you do not accept this License.  Therefore, by
     184modifying or distributing the Program (or any work based on the
     185Program), you indicate your acceptance of this License to do so, and
     186all its terms and conditions for copying, distributing or modifying
     187the Program or works based on it.
     188
     189  6. Each time you redistribute the Program (or any work based on the
     190Program), the recipient automatically receives a license from the
     191original licensor to copy, distribute or modify the Program subject to
     192these terms and conditions.  You may not impose any further
     193restrictions on the recipients' exercise of the rights granted herein.
     194You are not responsible for enforcing compliance by third parties to
     195this License.
     196
     197  7. If, as a consequence of a court judgment or allegation of patent
     198infringement or for any other reason (not limited to patent issues),
     199conditions are imposed on you (whether by court order, agreement or
     200otherwise) that contradict the conditions of this License, they do not
     201excuse you from the conditions of this License.  If you cannot
     202distribute so as to satisfy simultaneously your obligations under this
     203License and any other pertinent obligations, then as a consequence you
     204may not distribute the Program at all.  For example, if a patent
     205license would not permit royalty-free redistribution of the Program by
     206all those who receive copies directly or indirectly through you, then
     207the only way you could satisfy both it and this License would be to
     208refrain entirely from distribution of the Program.
     209
     210If any portion of this section is held invalid or unenforceable under
     211any particular circumstance, the balance of the section is intended to
     212apply and the section as a whole is intended to apply in other
     213circumstances.
     214
     215It is not the purpose of this section to induce you to infringe any
     216patents or other property right claims or to contest validity of any
     217such claims; this section has the sole purpose of protecting the
     218integrity of the free software distribution system, which is
     219implemented by public license practices.  Many people have made
     220generous contributions to the wide range of software distributed
     221through that system in reliance on consistent application of that
     222system; it is up to the author/donor to decide if he or she is willing
     223to distribute software through any other system and a licensee cannot
     224impose that choice.
     225
     226This section is intended to make thoroughly clear what is believed to
     227be a consequence of the rest of this License.
     228
     229  8. If the distribution and/or use of the Program is restricted in
     230certain countries either by patents or by copyrighted interfaces, the
     231original copyright holder who places the Program under this License
     232may add an explicit geographical distribution limitation excluding
     233those countries, so that distribution is permitted only in or among
     234countries not thus excluded.  In such case, this License incorporates
     235the limitation as if written in the body of this License.
     236
     237  9. The Free Software Foundation may publish revised and/or new versions
     238of the General Public License from time to time.  Such new versions will
     239be similar in spirit to the present version, but may differ in detail to
     240address new problems or concerns.
     241
     242Each version is given a distinguishing version number.  If the Program
     243specifies a version number of this License which applies to it and "any
     244later version", you have the option of following the terms and conditions
     245either of that version or of any later version published by the Free
     246Software Foundation.  If the Program does not specify a version number of
     247this License, you may choose any version ever published by the Free Software
     248Foundation.
     249
     250  10. If you wish to incorporate parts of the Program into other free
     251programs whose distribution conditions are different, write to the author
     252to ask for permission.  For software which is copyrighted by the Free
     253Software Foundation, write to the Free Software Foundation; we sometimes
     254make exceptions for this.  Our decision will be guided by the two goals
     255of preserving the free status of all derivatives of our free software and
     256of promoting the sharing and reuse of software generally.
     257
     258                            NO WARRANTY
     259
     260  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
     261FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
     262OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
     263PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
     264OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
     265MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
     266TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
     267PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
     268REPAIR OR CORRECTION.
     269
     270  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
     271WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
     272REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
     273INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
     274OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
     275TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
     276YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
     277PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
     278POSSIBILITY OF SUCH DAMAGES.
     279
     280                     END OF TERMS AND CONDITIONS
     281
     282            How to Apply These Terms to Your New Programs
     283
     284  If you develop a new program, and you want it to be of the greatest
     285possible use to the public, the best way to achieve this is to make it
     286free software which everyone can redistribute and change under these terms.
     287
     288  To do so, attach the following notices to the program.  It is safest
     289to attach them to the start of each source file to most effectively
     290convey the exclusion of warranty; and each file should have at least
     291the "copyright" line and a pointer to where the full notice is found.
     292
     293    <one line to give the program's name and a brief idea of what it does.>
     294    Copyright (C) <year>  <name of author>
     295
     296    This program is free software; you can redistribute it and/or modify
     297    it under the terms of the GNU General Public License as published by
     298    the Free Software Foundation; either version 2 of the License, or
     299    (at your option) any later version.
     300
     301    This program is distributed in the hope that it will be useful,
     302    but WITHOUT ANY WARRANTY; without even the implied warranty of
     303    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     304    GNU General Public License for more details.
     305
     306    You should have received a copy of the GNU General Public License along
     307    with this program; if not, write to the Free Software Foundation, Inc.,
     308    51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
     309
     310Also add information on how to contact you by electronic and paper mail.
     311
     312If the program is interactive, make it output a short notice like this
     313when it starts in an interactive mode:
     314
     315    Gnomovision version 69, Copyright (C) year name of author
     316    Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
     317    This is free software, and you are welcome to redistribute it
     318    under certain conditions; type `show c' for details.
     319
     320The hypothetical commands `show w' and `show c' should show the appropriate
     321parts of the General Public License.  Of course, the commands you use may
     322be called something other than `show w' and `show c'; they could even be
     323mouse-clicks or menu items--whatever suits your program.
     324
     325You should also get your employer (if you work as a programmer) or your
     326school, if any, to sign a "copyright disclaimer" for the program, if
     327necessary.  Here is a sample; alter the names:
     328
     329  Yoyodyne, Inc., hereby disclaims all copyright interest in the program
     330  `Gnomovision' (which makes passes at compilers) written by James Hacker.
     331
     332  <signature of Ty Coon>, 1 April 1989
     333  Ty Coon, President of Vice
     334
     335This General Public License does not permit incorporating your program into
     336proprietary programs.  If your program is a subroutine library, you may
     337consider it more useful to permit linking proprietary applications with the
     338library.  If this is what you want to do, use the GNU Lesser General
     339Public License instead of this License.
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/README.md

    r2801406 r3321269  
    4646e.g. `docker-compose run --rm test vendor/bin/phpunit` instead of `make test`.
    4747
    48 ## Crafted by Inpsyde
     48## Copyright and License
    4949
    50 The team at [Inpsyde][] is engineering the Web since 2006.
    51 
    52 ## License
    53 
    54 This module is provided under the [MIT](https://opensource.org/licenses/MIT) license.
    55 
     50This package is [free software](https://www.gnu.org/philosophy/free-sw.en.html) distributed under the terms of the GNU General Public License version 2 or (at your option) any later version. For the full license, see [LICENSE](./LICENSE).
    5651
    5752## Contributing
     
    6459[PSR-17(HTTP Factory)]: https://packagist.org/providers/psr/http-factory-implementation
    6560[PSR-18(HTTP Client)]: https://packagist.org/providers/psr/http-client-implementation
    66 [Inpsyde]: https://inpsyde.com
     61[Syde]: https://syde.com
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/inc/services.php

    r3260742 r3321269  
    8282use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Phone\PhoneSerializer;
    8383use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Phone\PhoneSerializerInterface;
    84 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelDeserializer;
    85 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelDeserializerInterface;
    86 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelFactory;
    87 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelFactoryInterface;
    88 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelSerializer;
    89 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelSerializerInterface;
    9084use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Product\ProductDeserializer;
    9185use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Product\ProductDeserializerInterface;
     
    210204    }, 'payoneer_sdk.registration_factory' => static function (): RegistrationFactoryInterface {
    211205        return new RegistrationFactory();
    212     }, 'payoneer_sdk.processing_model_factory' => static function (): ProcessingModelFactoryInterface {
    213         return new ProcessingModelFactory();
    214206    }, 'payoneer_sdk.networks_factory' => static function (): NetworksFactoryInterface {
    215207        return new NetworksFactory();
     
    300292        /** @var ProductDeserializerInterface $productDeserializer */
    301293        $productDeserializer = $container->get('payoneer_sdk.product_deserializer');
    302         /** @var ProcessingModelDeserializerInterface $processingModelDeserializer */
    303         $processingModelDeserializer = $container->get('payoneer_sdk.processing_model_deserializer');
    304294        /** @var NetworksDeserializer $networksDeserializer */
    305295        $networksDeserializer = $container->get('payoneer_sdk.networks_deserializer');
    306         return new ListDeserializer($listFactory, $callbackDeserializer, $customerDeserializer, $paymentDeserializer, $statusDeserializer, $redirectDeserializer, $identificationDeserializer, $styleDeserializer, $productDeserializer, $processingModelDeserializer, $networksDeserializer);
     296        return new ListDeserializer($listFactory, $callbackDeserializer, $customerDeserializer, $paymentDeserializer, $statusDeserializer, $redirectDeserializer, $identificationDeserializer, $styleDeserializer, $productDeserializer, $networksDeserializer);
    307297    }, 'payoneer_sdk.redirect_deserializer' => static function (ContainerInterface $container): RedirectDeserializerInterface {
    308298        $redirectFactory = $container->get('payoneer_sdk.redirect_factory');
     
    323313        /** @var PhoneSerializerInterface */
    324314        return new CustomerSerializer($phoneSerializer, $addressSerializer, $registrationSerializer, $nameSerializer);
    325     }, 'payoneer_sdk.processing_model_deserializer' => static function (ContainerInterface $container): ProcessingModelDeserializerInterface {
    326         /** @var ProcessingModelFactoryInterface $processingModelFactory */
    327         $processingModelFactory = $container->get('payoneer_sdk.processing_model_factory');
    328         return new ProcessingModelDeserializer($processingModelFactory);
    329315    }, 'payoneer_sdk.identification_serializer' => static function (): IdentificationSerializerInterface {
    330316        return new IdentificationSerializer();
     
    370356        /** @var  ProductSerializerInterface $productSerializer */
    371357        $productSerializer = $container->get('payoneer_sdk.product_serializer');
    372         /** @var ProcessingModelSerializerInterface $processingModelSerializer */
    373         $processingModelSerializer = $container->get('payoneer_sdk.processing_model_serializer');
    374358        /** @var NetworksSerializer $networksSerializer */
    375359        $networksSerializer = $container->get('payoneer_sdk.networks_serializer');
    376         return new ListSerializer($identificationSerializer, $paymentSerializer, $statusSerializer, $customerSerializer, $styleSerializer, $redirectSerializer, $productSerializer, $processingModelSerializer, $networksSerializer);
     360        return new ListSerializer($identificationSerializer, $paymentSerializer, $statusSerializer, $customerSerializer, $styleSerializer, $redirectSerializer, $productSerializer, $networksSerializer);
    377361    }, 'payoneer_sdk.commands.update_request_path_template' => static function (): string {
    378362        return 'lists/%1$s';
     
    397381        $validator = new InteractionCodeValidator($errorCodes);
    398382        return $validator;
    399     }, 'payoneer_sdk.processing_model_serializer' => static function (): ProcessingModelSerializerInterface {
    400         return new ProcessingModelSerializer();
    401383    }, 'payoneer_sdk.default_country' => static function (): string {
    402384        return 'US';
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/Customer/Customer.php

    r3111876 r3321269  
    1414     * Customer identifier given by merchant.
    1515     *
    16      * @var string
     16     * @var string|null
    1717     */
    1818    protected $number;
     
    5656     * @param NameInterface|null $name Object containing customer name.
    5757     */
    58     public function __construct(string $number, array $phones = null, array $addresses = null, string $email = null, string $deliveryEmail = null, RegistrationInterface $registration = null, NameInterface $name = null)
     58    public function __construct(string $number = null, array $phones = null, array $addresses = null, string $email = null, string $deliveryEmail = null, RegistrationInterface $registration = null, NameInterface $name = null)
    5959    {
    6060        $this->number = $number;
     
    7171    public function getNumber(): string
    7272    {
     73        if ($this->number === null) {
     74            throw new ApiException('number field is not set');
     75        }
    7376        return $this->number;
    7477    }
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/Customer/CustomerDeserializer.php

    r3111876 r3321269  
    5151    public function deserializeCustomer(array $customerData): CustomerInterface
    5252    {
    53         if (!isset($customerData['number'])) {
    54             throw new ApiException('Data contains no expected number element.');
    55         }
    56         $number = $customerData['number'];
     53        $number = $customerData['number'] ?? null;
    5754        if (isset($customerData['phones'])) {
    5855            $phonesData = $customerData['phones'];
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/Customer/CustomerDeserializerInterface.php

    r3111876 r3321269  
    1212    /**
    1313     * @param array {
    14      *     number: string,
     14     *     number?: string,
    1515     *     phones?: array {
    1616     *          mobile: array {
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/Customer/CustomerFactory.php

    r3111876 r3321269  
    1111     * @inheritDoc
    1212     */
    13     public function createCustomer(string $number, array $phones = null, array $addresses = null, string $email = null, string $deliveryEmail = null, RegistrationInterface $registration = null, NameInterface $name = null): CustomerInterface
     13    public function createCustomer(string $number = null, array $phones = null, array $addresses = null, string $email = null, string $deliveryEmail = null, RegistrationInterface $registration = null, NameInterface $name = null): CustomerInterface
    1414    {
    1515        return new Customer($number, $phones, $addresses, $email, $deliveryEmail, $registration, $name);
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/Customer/CustomerFactoryInterface.php

    r3111876 r3321269  
    1717     * Create a new Customer instance.
    1818     *
    19      * @param string $number Customer identifier provided by merchant.
     19     * @param string|null $number Customer identifier provided by merchant.
    2020     * @param array{mobile: PhoneInterface}|null $phones Map of customer phones.
    2121     * @param array{billing: AddressInterface, shipping?: AddressInterface}|null $addresses Addresses.
     
    2929     * @throws ApiExceptionInterface If failed to create customer object.
    3030     */
    31     public function createCustomer(string $number, array $phones = null, array $addresses = null, string $email = null, string $deliveryEmail = null, RegistrationInterface $registration = null, NameInterface $name = null): CustomerInterface;
     31    public function createCustomer(string $number = null, array $phones = null, array $addresses = null, string $email = null, string $deliveryEmail = null, RegistrationInterface $registration = null, NameInterface $name = null): CustomerInterface;
    3232}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/Customer/CustomerInterface.php

    r3111876 r3321269  
    1515    /**
    1616     * @return string Customer identifier given by merchant.
     17     *
     18     * @throws ApiExceptionInterface If this field not set.
    1719     */
    1820    public function getNumber(): string;
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/Customer/CustomerSerializer.php

    r3111876 r3321269  
    4343    /**
    4444     * @inheritDoc
     45     *
     46     * @todo: consider refactoring
    4547     */
     48    // phpcs:ignore Inpsyde.CodeQuality.FunctionLength.TooLong
    4649    public function serializeCustomer(CustomerInterface $customer): array
    4750    {
    48         $serializedCustomer = ['number' => $customer->getNumber()];
     51        $serializedCustomer = [];
     52        try {
     53            $serializedCustomer['number'] = $customer->getNumber();
     54        } catch (ApiExceptionInterface $apiException) {
     55            //this is an optional field, so it's ok to not have it
     56        }
    4957        try {
    5058            $customerPhones = $customer->getPhones();
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/Customer/CustomerSerializerInterface.php

    r3111876 r3321269  
    1515     *
    1616     * @return array {
    17      *     number: string,
     17     *     number?: string,
    1818     *     phones?: array{mobile: array{unstructuredNumber: string}},
    1919     *     addresses?: array{billing: AddressInterface, shipping?: AddressInterface},
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/ListSession/ListDeserializer.php

    r3111876 r3321269  
    1010use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Network\NetworksDeserializerInterface;
    1111use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Payment\PaymentDeserializerInterface;
    12 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelDeserializerInterface;
    1312use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Product\ProductDeserializerInterface;
    1413use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Redirect\RedirectDeserializerInterface;
     
    5453    protected $productDeserializer;
    5554    /**
    56      * @var ProcessingModelDeserializerInterface
    57      */
    58     protected $processingModelDeserializer;
    59     /**
    6055     * @var NetworksDeserializerInterface
    6156     */
     
    7166     * @param StyleDeserializerInterface $styleDeserializer To create style instance from data map.
    7267     * @param ProductDeserializerInterface $productDeserializer To create product instances.
    73      * @param ProcessingModelDeserializerInterface $processingModelDeserializer To create processing model instance from
    74      *  data map.
    7568     */
    76     public function __construct(ListFactoryInterface $listFactory, CallbackDeserializerInterface $callbackDeserializer, CustomerDeserializerInterface $customerDeserializer, PaymentDeserializerInterface $paymentDeserializer, StatusDeserializerInterface $statusDeserializer, RedirectDeserializerInterface $redirectDeserializer, IdentificationDeserializerInterface $identificationDeserializer, StyleDeserializerInterface $styleDeserializer, ProductDeserializerInterface $productDeserializer, ProcessingModelDeserializerInterface $processingModelDeserializer, NetworksDeserializerInterface $networksDeserializer)
     69    public function __construct(ListFactoryInterface $listFactory, CallbackDeserializerInterface $callbackDeserializer, CustomerDeserializerInterface $customerDeserializer, PaymentDeserializerInterface $paymentDeserializer, StatusDeserializerInterface $statusDeserializer, RedirectDeserializerInterface $redirectDeserializer, IdentificationDeserializerInterface $identificationDeserializer, StyleDeserializerInterface $styleDeserializer, ProductDeserializerInterface $productDeserializer, NetworksDeserializerInterface $networksDeserializer)
    7770    {
    7871        $this->listFactory = $listFactory;
     
    8578        $this->redirectDeserializer = $redirectDeserializer;
    8679        $this->productDeserializer = $productDeserializer;
    87         $this->processingModelDeserializer = $processingModelDeserializer;
    8880        $this->networksDeserializer = $networksDeserializer;
    8981    }
     
    111103        $redirect = isset($listData['redirect']) ? $this->redirectDeserializer->deserializeRedirect($listData['redirect']) : null;
    112104        $division = $listData['division'] ?? null;
    113         $processingModel = isset($listData['processingModel']) ? $this->processingModelDeserializer->deserializeProcessingModel($listData['processingModel']) : null;
    114105        $networks = isset($listData['networks']) ? $this->networksDeserializer->deserializeNetworks($listData['networks']) : null;
    115106        $products = array_map(function (array $productData) {
    116107            return $this->productDeserializer->deserializeProduct($productData);
    117108        }, $listData['products'] ?? []);
    118         return $this->listFactory->createList($links, $identification, $status, $payment, $customer, $style, $redirect, $division, $products, $processingModel, $networks);
     109        return $this->listFactory->createList($links, $identification, $status, $payment, $customer, $style, $redirect, $division, $products, $networks);
    119110    }
    120111}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/ListSession/ListDeserializerInterface.php

    r3111876 r3321269  
    4545     *                  taxCode?: string,
    4646     *              }[],
    47      *              division?: string,
    48      *              processingModel?: array{
    49      *                  code: string,
    50      *                  type: string
    51      *              }
     47     *              division?: string
    5248     * } $listData
    5349     *
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/ListSession/ListFactory.php

    r3111876 r3321269  
    88use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Network\NetworksInterface;
    99use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Payment\PaymentInterface;
    10 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelInterface;
    1110use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Redirect\RedirectInterface;
    1211use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Status\StatusInterface;
     
    1716     * @inheritDoc
    1817     */
    19     public function createList(array $links, IdentificationInterface $identification, StatusInterface $status, PaymentInterface $payment = null, CustomerInterface $customer = null, StyleInterface $style = null, RedirectInterface $redirect = null, string $division = null, array $products = null, ProcessingModelInterface $processingModel = null, NetworksInterface $networks = null): ListInterface
     18    public function createList(array $links, IdentificationInterface $identification, StatusInterface $status, PaymentInterface $payment = null, CustomerInterface $customer = null, StyleInterface $style = null, RedirectInterface $redirect = null, string $division = null, array $products = null, NetworksInterface $networks = null): ListInterface
    2019    {
    21         return new ListSession($links, $identification, $status, $payment, $customer, $style, $redirect, $division, $products, $processingModel, $networks);
     20        return new ListSession($links, $identification, $status, $payment, $customer, $style, $redirect, $division, $products, $networks);
    2221    }
    2322}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/ListSession/ListFactoryInterface.php

    r3111876 r3321269  
    1010use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Payment\PaymentInterface;
    1111use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Product\ProductInterface;
    12 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelInterface;
    1312use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Redirect\RedirectInterface;
    1413use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Status\StatusInterface;
     
    3736     * @throws ApiExceptionInterface If something went wrong.
    3837     */
    39     public function createList(array $links, IdentificationInterface $identification, StatusInterface $status, PaymentInterface $payment = null, CustomerInterface $customer = null, StyleInterface $style = null, RedirectInterface $redirect = null, string $division = null, array $products = null, ProcessingModelInterface $processingModel = null, NetworksInterface $networks = null): ListInterface;
     38    public function createList(array $links, IdentificationInterface $identification, StatusInterface $status, PaymentInterface $payment = null, CustomerInterface $customer = null, StyleInterface $style = null, RedirectInterface $redirect = null, string $division = null, array $products = null, NetworksInterface $networks = null): ListInterface;
    4039}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/ListSession/ListInterface.php

    r3111876 r3321269  
    1010use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Payment\PaymentInterface;
    1111use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Product\ProductInterface;
    12 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelInterface;
    1312use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Redirect\RedirectInterface;
    1413use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Status\StatusInterface;
     
    9089    public function getProducts(): array;
    9190    /**
    92      * Return processing model
    93      *
    94      * @return ProcessingModelInterface
    95      *
    96      * @throws ApiExceptionInterface If no processing model set.
    97      */
    98     public function getProcessingModel(): ProcessingModelInterface;
    99     /**
    10091     * Return networks
    10192     *
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/ListSession/ListSerializer.php

    r3111876 r3321269  
    99use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Network\NetworksSerializerInterface;
    1010use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Payment\PaymentSerializerInterface;
    11 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelSerializerInterface;
    1211use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Product\ProductInterface;
    1312use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Product\ProductSerializerInterface;
     
    4241    protected $redirectSerializer;
    4342    /**
    44      * @var ProcessingModelSerializerInterface
    45      */
    46     private $processingModelSerializer;
    47     /**
    4843     * @var ProductSerializerInterface
    4944     */
     
    6257     * @param RedirectSerializerInterface $redirectSerializer To serialize redirect instance.
    6358     */
    64     public function __construct(IdentificationSerializerInterface $identificationSerializer, PaymentSerializerInterface $paymentSerializer, StatusSerializerInterface $statusSerializer, CustomerSerializerInterface $customerSerializer, StyleSerializerInterface $styleSerializer, RedirectSerializerInterface $redirectSerializer, ProductSerializerInterface $productSerializer, ProcessingModelSerializerInterface $processingModelSerializer, NetworksSerializerInterface $networksSerializer)
     59    public function __construct(IdentificationSerializerInterface $identificationSerializer, PaymentSerializerInterface $paymentSerializer, StatusSerializerInterface $statusSerializer, CustomerSerializerInterface $customerSerializer, StyleSerializerInterface $styleSerializer, RedirectSerializerInterface $redirectSerializer, ProductSerializerInterface $productSerializer, NetworksSerializerInterface $networksSerializer)
    6560    {
    6661        $this->identificationSerializer = $identificationSerializer;
     
    7065        $this->styleSerializer = $styleSerializer;
    7166        $this->redirectSerializer = $redirectSerializer;
    72         $this->processingModelSerializer = $processingModelSerializer;
    7367        $this->productSerializer = $productSerializer;
    7468        $this->networksSerializer = $networksSerializer;
     
    116110        }
    117111        try {
    118             $processingModel = $listSession->getProcessingModel();
    119             $listData['processingModel'] = $this->processingModelSerializer->serializeProcessingModel($processingModel);
    120         } catch (ApiExceptionInterface $exception) {
    121             //Processing model is an optional parameter, so it's ok to have an exception here.
    122         }
    123         try {
    124112            $networks = $listSession->getNetworks();
    125113            $listData['networks'] = $this->networksSerializer->serializeNetworks($networks);
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/ListSession/ListSerializerInterface.php

    r3111876 r3321269  
    3434     *      taxCode?: string,
    3535     *     }[]
    36      *     division?: string,
    37      *     processingModel?: array{code: string, type: string},
     36     *     division?: string
    3837     * } Serialized LIST session
    3938     */
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-sdk/src/Api/Entities/ListSession/ListSession.php

    r3111876 r3321269  
    1010use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Payment\PaymentInterface;
    1111use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Product\ProductInterface;
    12 use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\ProcessingModel\ProcessingModelInterface;
    1312use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Redirect\RedirectInterface;
    1413use Syde\Vendor\Inpsyde\PayoneerSdk\Api\Entities\Status\StatusInterface;
     
    4948    protected $division;
    5049    /**
    51      * @var ProcessingModelInterface|null
    52      */
    53     protected $processingModel;
    54     /**
    5550     * @var ProductInterface[]
    5651     */
     
    7065     * @param string|null $division Division name of this transaction
    7166     * @param ProductInterface[] $products Products in the current LIST session
    72      * @param ProcessingModelInterface|null $processingModel
    7367     */
    74     public function __construct(array $links, IdentificationInterface $identification, StatusInterface $status, PaymentInterface $payment = null, CustomerInterface $customer = null, StyleInterface $style = null, RedirectInterface $redirect = null, string $division = null, array $products = null, ProcessingModelInterface $processingModel = null, NetworksInterface $networks = null)
     68    public function __construct(array $links, IdentificationInterface $identification, StatusInterface $status, PaymentInterface $payment = null, CustomerInterface $customer = null, StyleInterface $style = null, RedirectInterface $redirect = null, string $division = null, array $products = null, NetworksInterface $networks = null)
    7569    {
    7670        $this->customer = $customer;
     
    8579            $this->products = $products;
    8680        }
    87         $this->processingModel = $processingModel;
    8881        $this->networks = $networks;
    8982    }
     
    169162     * @inheritDoc
    170163     */
    171     public function getProcessingModel(): ProcessingModelInterface
    172     {
    173         if (!$this->processingModel) {
    174             throw new ApiException('No processing model found in the LIST session');
    175         }
    176         return $this->processingModel;
    177     }
    178     /**
    179      * @inheritDoc
    180      */
    181164    public function getNetworks(): NetworksInterface
    182165    {
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-settings/assets/admin-payment-methods.asset.php

    r3120336 r3321269  
    33namespace Syde\Vendor;
    44
    5 return array('dependencies' => array(), 'version' => 'a471735326cf6485a583');
     5return array('dependencies' => array(), 'version' => '56c23b532049ed5b3065');
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-settings/assets/admin-payment-methods.js

    r3120336 r3321269  
    1 !function(e,t){var a=e.PayoneerData,l=a.paymentMethods,o=a.helpTipMessage,n=a.generalSettingsUrl;l.forEach((function(e){var a=t.querySelector('[data-gateway_id="'.concat(e,'"] .wc-payment-gateway-method-toggle-enabled'));a.querySelector(".woocommerce-input-toggle",a).style.opacity=.4;var l=t.createElement("span");l.className="woocommerce-help-tip",l.setAttribute("aria-label",o),l.setAttribute("data-tip",o),l.style.display="inline",l.style.verticalAlign="bottom",l.style.margin="0",a.appendChild(l),a.href=n}))}(window,document,jQuery);
     1!function(e,t){var a=e.PayoneerData,l=a.paymentMethods,o=a.helpTipMessage,n=a.generalSettingsUrl;l.forEach(function(e){var a=t.querySelector('[data-gateway_id="'.concat(e,'"] .wc-payment-gateway-method-toggle-enabled'));a.querySelector(".woocommerce-input-toggle",a).style.opacity=.4;var l=t.createElement("span");l.className="woocommerce-help-tip",l.setAttribute("aria-label",o),l.setAttribute("data-tip",o),l.style.display="inline",l.style.verticalAlign="bottom",l.style.margin="0",a.appendChild(l),a.href=n})}(window,document,jQuery);
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-settings/assets/admin-settings.asset.php

    r3111876 r3321269  
    33namespace Syde\Vendor;
    44
    5 return array('dependencies' => array(), 'version' => '2b8606b14cc812c5f545');
     5return array('dependencies' => array(), 'version' => '8ceb6fd38758d8cf91cc');
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-settings/assets/admin-settings.js

    r3111876 r3321269  
    1 !function(e,t,n){n((function(){var e=function(e,t){var r=t.find("[group=sandbox_credentials]"),o=t.find("[group=live_credentials]");r.add(o).each((function(){n(this).attr("readonly","readonly")})),t.find("[group = ".concat(e,"]")).each((function(){n(this).removeAttr("readonly")}))},r=function(e){return e?"live_credentials":"sandbox_credentials"},o=n("#woocommerce_payoneer-checkout_live_mode"),a=o.closest("form");o.on("change",(function(){var t=this.checked,o=n(this).closest("form");e(r(t),o)})),e(r(o.prop("checked")),a);var i=function(){return confirm(PayoneerData.i18n.confirmReset)};t.querySelectorAll("button[data-target]").forEach((function(e){e.addEventListener("click",(function(n){t.querySelector(e.dataset.target).dispatchEvent(new CustomEvent("reset",{detail:e.dataset.default})),n.preventDefault()}))})),t.querySelectorAll("#mainform input").forEach((function(e){e.addEventListener("reset",(function(t){i()&&(e.value=t.detail)}))})),t.querySelectorAll("#mainform textarea").forEach((function(e){e.addEventListener("reset",(function(t){i()&&(e.innerHTML=t.detail,n(e).next(".CodeMirror")[0].CodeMirror.setValue(e.value),n(e).next(".CodeMirror")[0].CodeMirror.refresh())}))}))}))}(top,document,jQuery);
     1!function(e,t,n){n(function(){var e=function(e,t){var r=t.find("[group=sandbox_credentials]"),o=t.find("[group=live_credentials]");r.add(o).each(function(){n(this).attr("readonly","readonly")}),t.find("[group = ".concat(e,"]")).each(function(){n(this).removeAttr("readonly")})},r=function(e){return e?"live_credentials":"sandbox_credentials"},o=n("#woocommerce_payoneer-checkout_live_mode"),a=o.closest("form");o.on("change",function(){var t=this.checked,o=n(this).closest("form");e(r(t),o)}),e(r(o.prop("checked")),a);var i=function(){return confirm(PayoneerData.i18n.confirmReset)};t.querySelectorAll("button[data-target]").forEach(function(e){e.addEventListener("click",function(n){t.querySelector(e.dataset.target).dispatchEvent(new CustomEvent("reset",{detail:e.dataset.default})),n.preventDefault()})}),t.querySelectorAll("#mainform input").forEach(function(e){e.addEventListener("reset",function(t){i()&&(e.value=t.detail)})}),t.querySelectorAll("#mainform textarea").forEach(function(e){e.addEventListener("reset",function(t){i()&&(e.innerHTML=t.detail,n(e).next(".CodeMirror")[0].CodeMirror.setValue(e.value),n(e).next(".CodeMirror")[0].CodeMirror.refresh())})})})}(top,document,jQuery);
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-status-report/inc/services.php

    r3111876 r3321269  
    99namespace Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport;
    1010
     11use WP_REST_Request;
     12use WP_REST_Response;
    1113use Syde\Vendor\Psr\Container\ContainerInterface;
     14use Syde\Vendor\Dhii\Services\Factories\Alias;
     15use Syde\Vendor\Dhii\Services\Factories\Constructor;
     16use Syde\Vendor\Dhii\Services\Factories\Value;
     17use Syde\Vendor\Dhii\Services\Factory;
     18use Syde\Vendor\Dhii\Services\Service;
     19use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport\Data\SystemReportCollector;
     20use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport\Data\SystemReportParamsDTO;
     21use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport\Data\LogCollector\LogCollectorFactory;
     22use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport\Email\SystemReportEmailSender;
     23use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport\Email\SystemReportFormatter;
     24use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport\Endpoint\SystemReportEndpointController;
     25use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport\Permission\SystemReportPermissionHandler;
     26use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\Controller\WpRestApiControllerInterface;
    1227return static function (): array {
     28    $moduleRoot = dirname(__DIR__);
    1329    return ['status-report.renderer' => static function (): Renderer {
    1430        return new Renderer();
    15     }, 'status-report.boolToHtml' => static function (): object {
    16         return new class
    17         {
    18             public function convert(bool $value): string
    19             {
    20                 return $value ? '<mark class="yes"><span class="dashicons dashicons-yes"></span></mark>' : '<mark class="no">&ndash;</mark>';
    21             }
    22         };
    2331    }, 'status-report.fields' => static function (ContainerInterface $container): array {
    2432        return [['label' => esc_html__('Shop country code', 'payoneer-checkout'), 'exported_label' => 'Shop country code', 'description' => esc_html__('Country / State value on Settings / General / Store Address.', 'payoneer-checkout'), 'value' => $container->get('inpsyde_payment_gateway.store_country')], ['label' => esc_html__('API username', 'payoneer-checkout'), 'exported_label' => 'API username', 'value' => $container->get('payoneer_settings.merchant_code')], ['label' => esc_html__('Payment flow', 'payoneer-checkout'), 'exported_label' => 'Payment flow', 'description' => esc_html__('Displays whether a plugin is using a hosted or an embedded payment flow', 'payoneer-checkout'), 'value' => $container->get('checkout.selected_payment_flow')]];
    25     }];
     33    }, 'status-report.options' => new Alias('core.options'), 'status-report.namespace' => new Alias('core.webhooks.namespace'), 'status-report.rest_route' => new Value('/system-report'), 'status-report.allowed_methods' => new Value(['POST']), 'status-report.html-template' => Service::fromFile("{$moduleRoot}/inc/html-template.php"), 'status-report.email.recipient' => new Value('l2checkoutsupport@payoneer.com'), 'status-report.email.subject' => new Value('Automated System Report - {SITE_NAME}'), 'status-report.email.message' => Service::fromFile("{$moduleRoot}/inc/email-message.php"), 'status-report.email.formatter' => new Constructor(SystemReportFormatter::class, ['core.plugin.version_string', 'status-report.html-template']), 'status-report.email.sender' => new Constructor(SystemReportEmailSender::class, ['status-report.email.recipient', 'status-report.email.subject', 'status-report.email.message', 'status-report.email.formatter', 'payoneer_settings.merchant']), 'status-report.background_processor' => new Factory([], static function (): callable {
     34        return static function (SystemReportParamsDTO $params): array {
     35            // Schedule the task as a background job: This is where the actual work happens.
     36            $scheduled = wp_schedule_single_event(time(), 'payoneer_process_system_report', [$params], \true);
     37            if (\true !== $scheduled) {
     38                return ['success' => \false, 'message' => $scheduled->get_error_message()];
     39            }
     40            return ['success' => \true];
     41        };
     42    }), 'status-report.controller' => new Constructor(SystemReportEndpointController::class, ['status-report.background_processor']), 'status-report.callback' => new Factory(['status-report.controller'], static function (WpRestApiControllerInterface $controller): callable {
     43        return static fn(WP_REST_Request $request): WP_REST_Response => $controller->handleWpRestRequest($request);
     44    }), 'status-report.permission_handler' => new Constructor(SystemReportPermissionHandler::class, ['status-report.options', 'payoneer_settings.merchant']), 'status-report.permission_callback' => new Factory(['status-report.permission_handler'], static function (SystemReportPermissionHandler $handler): callable {
     45        return static fn(WP_REST_Request $request) => $handler->checkPermission($request);
     46    }), 'status-report.log-file-collector-factory' => new Constructor(LogCollectorFactory::class, ['inpsyde_logger.logging_source']), 'status-report.collector' => new Constructor(SystemReportCollector::class, ['status-report.log-file-collector-factory', 'wp.order_finder']), 'status-report.settings.fields' => Service::fromFile("{$moduleRoot}/inc/fields.php")];
    2647};
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-status-report/src/Renderer.php

    r3114998 r3321269  
    2424     * @param string $title The title.
    2525     * @param StatusReportItem[]  $items The items.
    26      * @return false|string
     26     * @return string
    2727     */
    28     public function render(string $title, array $items)
     28    public function render(string $title, array $items): string
    2929    {
    3030        ob_start();
     
    6767        </table>
    6868        <?php
    69         return ob_get_clean();
     69        return (string) ob_get_clean();
    7070    }
    7171}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-status-report/src/StatusReportModule.php

    r3111876 r3321269  
    66use Syde\Vendor\Inpsyde\Modularity\Module\ServiceModule;
    77use Syde\Vendor\Inpsyde\Modularity\Module\ExecutableModule;
     8use Syde\Vendor\Inpsyde\Modularity\Module\ExtendingModule;
    89use Syde\Vendor\Inpsyde\Modularity\Module\ModuleClassNameIdTrait;
     10use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport\Data\SystemReportCollectorInterface;
     11use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport\Data\SystemReportParamsDTO;
     12use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\StatusReport\Email\SystemReportEmailSenderInterface;
    913use Syde\Vendor\Psr\Container\ContainerInterface;
    1014/**
    1115 * @psalm-import-type StatusReportItem from Renderer
    1216 */
    13 class StatusReportModule implements ServiceModule, ExecutableModule
     17class StatusReportModule implements ServiceModule, ExecutableModule, ExtendingModule
    1418{
    1519    use ModuleClassNameIdTrait;
     
    4044    public function run(ContainerInterface $container): bool
    4145    {
     46        /**
     47         * Extend the default WooCommerce system status report.
     48         *
     49         * @see /wp-admin/admin.php?page=wc-status
     50         */
    4251        add_action('woocommerce_system_status_report', static function () use ($container) {
    4352            $statusReportRenderer = $container->get('status-report.renderer');
     
    4554            /** @var StatusReportItem[] $statusReportItems */
    4655            $statusReportItems = $container->get('status-report.fields');
    47             echo wp_kses_post((string) $statusReportRenderer->render(esc_html__('Payoneer Checkout', 'payoneer-checkout'), $statusReportItems));
     56            echo wp_kses_post($statusReportRenderer->render(esc_html__('Payoneer Checkout', 'payoneer-checkout'), $statusReportItems));
     57        });
     58        // Register REST API endpoint
     59        add_action('rest_api_init', static function () use ($container) {
     60            /** @var string $namespace */
     61            $namespace = $container->get('status-report.namespace');
     62            /** @var string $route */
     63            $route = $container->get('status-report.rest_route');
     64            /** @var string[] $methods */
     65            $methods = $container->get('status-report.allowed_methods');
     66            /** @var callable $callback */
     67            $callback = $container->get('status-report.callback');
     68            /** @var callable(): bool $permissionCallback */
     69            $permissionCallback = $container->get('status-report.permission_callback');
     70            /**
     71             * The REST endpoint which triggers the system report mail.
     72             *
     73             * Endpoint:
     74             * POST /wp-json/inpsyde/payoneer-checkout/system-report
     75             */
     76            register_rest_route($namespace, $route, ['methods' => $methods, 'callback' => $callback, 'permission_callback' => $permissionCallback]);
     77        });
     78        // Cron event handler.
     79        add_action('payoneer_process_system_report', static function (SystemReportParamsDTO $params) use ($container) {
     80            $collector = $container->get('status-report.collector');
     81            assert($collector instanceof SystemReportCollectorInterface);
     82            $emailSender = $container->get('status-report.email.sender');
     83            assert($emailSender instanceof SystemReportEmailSenderInterface);
     84            $reportData = $collector->collect($params);
     85            $emailSender->sendReport($reportData, $params);
    4886        });
    4987        return \true;
    5088    }
     89    /**
     90     * @inheritDoc
     91     */
     92    public function extensions(): array
     93    {
     94        return ['payoneer_settings.settings_fields' => static function (array $previous, ContainerInterface $container): array {
     95            /** @var array $settingsFields */
     96            $settingsFields = $container->get('status-report.settings.fields');
     97            return array_merge($previous, $settingsFields);
     98        }];
     99    }
    51100}
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-webhooks/inc/services.php

    r3124685 r3321269  
    1313use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\Controller\OrderPaymentWebhookStrategyHandler;
    1414use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\LogIncomingWebhookRequest;
    15 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderFinder\HposOrderFinder;
    16 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderFinder\OrderFinderInterface;
    1715use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderPaymentWebhookHandler\CustomerRegistrationHandler;
    1816use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderPaymentWebhookHandler\FailedPaymentHandler;
     
    2119use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderPaymentWebhookHandler\RefundedPaymentHandler;
    2220use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\Controller\WpRestApiControllerInterface;
    23 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderFinder\AddTransactionIdFieldSupport;
    24 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderFinder\OrderFinder;
    2521use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderWebhookFinder\OrderWebhookFinder;
    26 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\RefundFinder\AddPayoutIdFieldSupport;
    27 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\RefundFinder\RefundFinder;
    28 use Syde\Vendor\Psr\Container\ContainerInterface;
    2922return static function (): array {
    3023    $moduleRoot = \dirname(__DIR__);
     
    3932            };
    4033        }),
    41         'webhooks.controller.payment_webhook_controller' => new Constructor(PaymentWebhookController::class, ['webhooks.order.security_header_field_name', 'webhooks.order_finder', 'webhooks.order_webhook_finder', 'webhooks.order.processed_id_field_name', 'webhooks.controller.payment_webhook_strategy_handler']),
     34        'webhooks.controller.payment_webhook_controller' => new Constructor(PaymentWebhookController::class, ['webhooks.order.security_header_field_name', 'wp.order_finder', 'webhooks.order_webhook_finder', 'webhooks.order.processed_id_field_name', 'webhooks.controller.payment_webhook_strategy_handler']),
    4235        'webhooks.controller.payment_webhook_strategy_handler' => new Constructor(OrderPaymentWebhookStrategyHandler::class, ['webhooks.failed_payment_handler', 'webhooks.chargeback_payment_handler', 'webhooks.refunded_payment_handler', 'webhooks.charged_payment_handler', 'webhooks.customer_registration_handler']),
    4336        'webhooks.log_incoming_webhooks_request' => new Constructor(LogIncomingWebhookRequest::class, ['webhooks.security_header_name']),
    4437        'webhooks.failed_payment_handler' => new Constructor(FailedPaymentHandler::class),
    4538        'webhooks.chargeback_payment_handler' => new Constructor(ChargeBackPaymentHandler::class),
    46         'webhooks.refunded_payment_handler' => new Constructor(RefundedPaymentHandler::class, ['webhooks.order.charge_id_field_name', 'webhooks.order_refund.payout_id_field_name', 'webhooks.refund_finder']),
     39        'webhooks.refunded_payment_handler' => new Constructor(RefundedPaymentHandler::class, ['webhooks.order.charge_id_field_name', 'webhooks.order_refund.payout_id_field_name', 'wp.refund_finder']),
    4740        'webhooks.charged_payment_handler' => new Constructor(ChargedPaymentHandler::class, ['webhooks.order.charge_id_field_name']),
    4841        'webhooks.customer_registration_handler' => new Constructor(CustomerRegistrationHandler::class, ['webhooks.customer_registration_id_field_name']),
    49         'webhooks.order_finder' => static function (ContainerInterface $container): OrderFinderInterface {
    50             $transactionIdFieldName = (string) $container->get('webhooks.order.transaction_id_field_name');
    51             $hposEnabled = (bool) $container->get('wc.hpos.is_enabled');
    52             return $hposEnabled ? new HposOrderFinder($transactionIdFieldName) : new OrderFinder($transactionIdFieldName);
    53         },
    54         'webhooks.refund_finder' => new Constructor(RefundFinder::class, ['webhooks.order_refund.payout_id_field_name']),
    5542        'webhooks.order_webhook_finder' => new Constructor(OrderWebhookFinder::class, ['webhooks.order.processed_id_field_name']),
    5643        'webhooks.controller.webhooks_controller' => new Factory(['webhooks.controller.payment_webhook_controller'], static function (WpRestApiControllerInterface $paymentWebhookController): WpRestApiControllerInterface {
     
    6350            return [\WP_REST_Server::READABLE, \WP_REST_Server::CREATABLE];
    6451        },
    65         'webhooks.add_transaction_id_field_support' => new Constructor(AddTransactionIdFieldSupport::class, ['webhooks.order.transaction_id_field_name']),
    66         'webhooks.add_payout_id_field_support' => new Constructor(AddPayoutIdFieldSupport::class, ['webhooks.order_refund.payout_id_field_name']),
    6752        'webhooks.settings.fields' => Service::fromFile("{$moduleRoot}/inc/fields.php"),
    6853        'webhooks.security_header_name' => new Value('List-Security-Token'),
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-webhooks/src/Controller/PaymentWebhookController.php

    r3124685 r3321269  
    44namespace Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\Controller;
    55
    6 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderFinder\OrderFinderInterface;
     6use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp\OrderFinder\OrderFinderInterface;
    77use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderWebhookFinder\OrderWebhookFinderInterface;
    88use WC_Order;
     
    5454    {
    5555        $transactionId = (string) $request->get_param('transactionId');
    56         $order = $this->orderFinder->findOrderByTransactionId($transactionId);
     56        $orders = $this->orderFinder->findOrdersByTransactionId($transactionId, 20);
     57        if (count($orders) > 1) {
     58            do_action('payoneer-checkout.webhook_request.multiple_orders_found_for_transaction_id', ['transactionId' => $transactionId, 'orders' => array_map(static fn(WC_Order $order) => $order->get_id(), $orders)]);
     59        }
     60        $order = $orders[0];
    5761        $longId = (string) $request->get_param('longId');
    5862        if (!$order instanceof WC_Order) {
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-webhooks/src/OrderPaymentWebhookHandler/RefundedPaymentHandler.php

    r3111876 r3321269  
    44namespace Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\OrderPaymentWebhookHandler;
    55
    6 use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Webhooks\RefundFinder\RefundFinderInterface;
     6use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp\RefundFinder\RefundFinderInterface;
    77use WC_Order;
    88use WC_Order_Refund;
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-webhooks/src/WebhooksModule.php

    r3111876 r3321269  
    3131            register_rest_route($namespace, $route, ['methods' => $methods, 'callback' => $callback, 'permission_callback' => $permissionCallback]);
    3232        });
    33         /** @var callable():void $addTransactionIdFieldSupport */
    34         $addTransactionIdFieldSupport = $container->get('webhooks.add_transaction_id_field_support');
    35         $addTransactionIdFieldSupport();
    36         /** @var callable():void $addPayoutIdFieldSupport */
    37         $addPayoutIdFieldSupport = $container->get('webhooks.add_payout_id_field_support');
    38         $addPayoutIdFieldSupport();
    3933        /** @var callable(WP_Rest_Request):void $logIncomingWebhookRequest */
    4034        $logIncomingWebhookRequest = $container->get('webhooks.log_incoming_webhooks_request');
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-wp/inc/factories.php

    r3305047 r3321269  
    4242    }
    4343    return $wooCommerce->session instanceof \WC_Session;
    44 }), 'wc.cart.is-available' => new Factory(['wc'], static fn(\WooCommerce $wooCommerce) => $wooCommerce->cart instanceof \WC_Cart)];
     44}), 'wc.cart.is-available' => new Factory(['wc'], static fn(\WooCommerce $wooCommerce) => $wooCommerce->cart instanceof \WC_Cart), 'wc.is_checkout_pay_page' => new Factory(['wc'], static function (): bool {
     45    return is_checkout_pay_page();
     46}), 'wc.is_order_received_page' => new Factory(['wc'], static function (): bool {
     47    return is_order_received_page();
     48})];
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-wp/inc/services.php

    r3305047 r3321269  
    77use Syde\Vendor\Dhii\Collection\MutableContainerInterface;
    88use Syde\Vendor\Dhii\Services\Factories\Alias;
     9use Syde\Vendor\Dhii\Services\Factories\Constructor;
    910use Syde\Vendor\Dhii\Services\Factories\Value;
    1011use Syde\Vendor\Dhii\Services\Factory;
     12use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Checkout\RequestHeaderUtil;
    1113use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Core\Exception\PayoneerException;
    1214use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Environment\WpEnvironmentInterface;
    1315use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp\NormalizingLocaleProviderISO639ISO3166;
    1416use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp\LocaleProviderInterface;
     17use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp\OrderFinder\AddTransactionIdFieldSupport;
     18use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp\OrderFinder\HposOrderFinder;
     19use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp\OrderFinder\OrderFinder;
     20use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp\OrderFinder\OrderFinderInterface;
     21use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp\RefundFinder\AddPayoutIdFieldSupport;
     22use Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp\RefundFinder\RefundFinder;
     23use Syde\Vendor\Psr\Container\ContainerInterface;
    1524use Syde\Vendor\WpOop\Containers\Options\BlogOptions;
    1625use Syde\Vendor\WpOop\Containers\Options\SiteMeta;
    1726return static function (): array {
    18     return ['wp.random_seed' => new Factory([], static function (): string {
    19         return \uniqid('', \true);
    20     }), 'wp.current_locale.wp' => new Factory([], static function (): string {
    21         return \determine_locale();
    22     }), 'wp.site.title' => new Factory([], static function (): string {
    23         return \get_bloginfo('name', 'display');
    24     }), 'wp.current_locale.fallback' => new Value(''), 'wp.current_locale.provider' => new Factory(['wp.current_locale.wp', 'wp.current_locale.fallback'], static function (string $internalLocale, string $defaultLocale): LocaleProviderInterface {
    25         return new NormalizingLocaleProviderISO639ISO3166($internalLocale, $defaultLocale);
    26     }), 'wp.current_locale.normalized' => new Factory(['wp.current_locale.provider'], static function (LocaleProviderInterface $localeProvider): string {
    27         return $localeProvider->provideLocale();
    28     }), 'wp.site_options.not_found_token' => new Alias('wp.random_seed'), 'wp.sites.current.id' => new Factory([], static function (): ?int {
    29         return \is_multisite() ? \get_current_blog_id() : null;
    30     }), 'wp.sites.current.options' => new Factory(['wp.sites.current.id', 'wp.site_options.not_found_token'], static function (?int $siteId, string $defaultToken): MutableContainerInterface {
    31         $product = new BlogOptions($siteId, $defaultToken);
    32         return $product;
    33     }), 'wp.sites.current.meta' => new Factory(['wp.sites.current.id'], static function (?int $siteId): MutableContainerInterface {
    34         $product = new SiteMeta($siteId);
    35         return $product;
    36     }), 'wp.http.wp_http_object' => new Factory([], static function (): \WP_Http {
    37         return \_wp_http_get_object();
    38     }), 'wp.admin_url' => new Factory([], static function (): string {
    39         return \admin_url();
    40     }), 'wp.is_admin' => new Factory([], static function (): bool {
    41         return \is_admin();
    42     }), 'wp.is_ajax' => new Factory([], static function (): bool {
    43         return \defined('DOING_AJAX') && \DOING_AJAX;
    44     }), 'wp.is_frontend_request' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): bool {
    45         return (!\is_admin() || \defined('DOING_AJAX')) && !\defined('DOING_CRON') && !\defined('REST_REQUEST') && !$wooCommerce->is_rest_api_request();
    46     }), 'wp.is_rest_api_request' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): bool {
    47         return $wooCommerce->is_rest_api_request();
    48     }), 'wp.site_url' => new Factory([], static function (): string {
    49         return \get_site_url(\get_current_blog_id());
    50     }), 'wp.is_debug' => new Value(\defined('WP_DEBUG') && \WP_DEBUG), 'wp.is_script_debug' => new Value(\defined('SCRIPT_DEBUG') && \SCRIPT_DEBUG), 'wp.user_id' => new Factory([], static function (): string {
    51         return (string) \get_current_user_id();
    52     }), 'wc' => new Factory([], static function (): \WooCommerce {
    53         if (!\did_action('woocommerce_init')) {
    54             throw new \RuntimeException('"wc" service was accessed before the "woocommerce_init" hook');
    55         }
    56         return \WC();
    57     }), 'wc.version' => new Factory(['core.wp_environment'], static function (WpEnvironmentInterface $wpEnvironment): string {
    58         return $wpEnvironment->getWcVersion();
    59     }), 'wc.session' => new Factory(['wc', 'wc.session.is-available'], static function (\WooCommerce $wooCommerce, bool $isAvailable): \WC_Session {
    60         if (!$isAvailable) {
    61             throw new PayoneerException('WooCommerce session is not available.');
    62         }
    63         return $wooCommerce->session;
    64     }), 'wc.customer' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): \WC_Customer {
    65         return $wooCommerce->customer;
    66     }), 'wc.cart' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): \WC_Cart {
    67         return $wooCommerce->cart;
    68     }), 'wc.currency' => new Factory(['wc'], static function (): string {
    69         return get_woocommerce_currency();
    70     }), 'wc.price_decimals' => new Factory(['wc'], static function (): int {
    71         return \wc_get_price_decimals();
    72     }), 'wc.settings.price_include_tax' => new Factory(['wc'], static function (): bool {
    73         return \wc_prices_include_tax();
    74     }), 'wc.is_fragment_update' => new Factory([], static function (): bool {
    75         $wcAjaxAction = \filter_input(\INPUT_GET, 'wc-ajax', \FILTER_CALLBACK, ['options' => 'sanitize_text_field']);
    76         return $wcAjaxAction === 'update_order_review' || $wcAjaxAction === 'update_checkout';
    77     }), 'wc.is_store_api_request' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): bool {
    78         /**
    79          * We really really wish to access raw data here.
    80          * Wea re also doing only string comparisons and will not use the data
    81          * for processing. Hence:
    82          * phpcs:disable WordPress.Security.ValidatedSanitizedInput.MissingUnslash
    83          * phpcs:disable WordPress.Security.ValidatedSanitizedInput.InputNotSanitized
    84          */
    85         global $wp_rewrite;
    86         \assert($wp_rewrite instanceof \WP_Rewrite);
    87         if ($wp_rewrite->using_permalinks()) {
    88             /**
    89              * is_store_api_request is not available <=8.9.1.
    90              * However, block checkout as a whole has been around far longer.
    91              * So for older WC versions, we execute a copy of the method we have today
    92              */
    93             if (!\method_exists($wooCommerce, 'is_store_api_request')) {
    94                 if (empty($_SERVER['REQUEST_URI'])) {
    95                     return \false;
     27    return [
     28        'wp.random_seed' => new Factory([], static function (): string {
     29            return \uniqid('', \true);
     30        }),
     31        'wp.current_locale.wp' => new Factory([], static function (): string {
     32            return \determine_locale();
     33        }),
     34        'wp.site.title' => new Factory([], static function (): string {
     35            return \get_bloginfo('name', 'display');
     36        }),
     37        'wp.current_locale.fallback' => new Value(''),
     38        'wp.current_locale.provider' => new Factory(['wp.current_locale.wp', 'wp.current_locale.fallback'], static function (string $internalLocale, string $defaultLocale): LocaleProviderInterface {
     39            return new NormalizingLocaleProviderISO639ISO3166($internalLocale, $defaultLocale);
     40        }),
     41        'wp.current_locale.normalized' => new Factory(['wp.current_locale.provider'], static function (LocaleProviderInterface $localeProvider): string {
     42            return $localeProvider->provideLocale();
     43        }),
     44        'wp.site_options.not_found_token' => new Alias('wp.random_seed'),
     45        'wp.sites.current.id' => new Factory([], static function (): ?int {
     46            return \is_multisite() ? \get_current_blog_id() : null;
     47        }),
     48        'wp.sites.current.options' => new Factory(['wp.sites.current.id', 'wp.site_options.not_found_token'], static function (?int $siteId, string $defaultToken): MutableContainerInterface {
     49            $product = new BlogOptions($siteId, $defaultToken);
     50            return $product;
     51        }),
     52        'wp.sites.current.meta' => new Factory(['wp.sites.current.id'], static function (?int $siteId): MutableContainerInterface {
     53            $product = new SiteMeta($siteId);
     54            return $product;
     55        }),
     56        'wp.http.wp_http_object' => new Factory([], static function (): \WP_Http {
     57            return \_wp_http_get_object();
     58        }),
     59        'wp.admin_url' => new Factory([], static function (): string {
     60            return \admin_url();
     61        }),
     62        'wp.is_admin' => new Factory([], static function (): bool {
     63            return \is_admin();
     64        }),
     65        'wp.is_ajax' => new Factory([], static function (): bool {
     66            return \defined('DOING_AJAX') && \DOING_AJAX;
     67        }),
     68        'wp.is_frontend_request' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): bool {
     69            return (!\is_admin() || \defined('DOING_AJAX')) && !\defined('DOING_CRON') && !\defined('REST_REQUEST') && !$wooCommerce->is_rest_api_request();
     70        }),
     71        'wp.is_rest_api_request' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): bool {
     72            return $wooCommerce->is_rest_api_request();
     73        }),
     74        'wp.site_url' => new Factory([], static function (): string {
     75            return \get_site_url(\get_current_blog_id());
     76        }),
     77        'wp.is_debug' => new Value(\defined('WP_DEBUG') && \WP_DEBUG),
     78        'wp.is_script_debug' => new Value(\defined('SCRIPT_DEBUG') && \SCRIPT_DEBUG),
     79        'wp.user_id' => new Factory([], static function (): string {
     80            return (string) \get_current_user_id();
     81        }),
     82        'wc' => new Factory([], static function (): \WooCommerce {
     83            if (!\did_action('woocommerce_init')) {
     84                throw new \RuntimeException('"wc" service was accessed before the "woocommerce_init" hook');
     85            }
     86            return \WC();
     87        }),
     88        'wc.version' => new Factory(['core.wp_environment'], static function (WpEnvironmentInterface $wpEnvironment): string {
     89            return $wpEnvironment->getWcVersion();
     90        }),
     91        'wc.session' => new Factory(['wc', 'wc.session.is-available'], static function (\WooCommerce $wooCommerce, bool $isAvailable): \WC_Session {
     92            if (!$isAvailable) {
     93                throw new PayoneerException('WooCommerce session is not available.');
     94            }
     95            return $wooCommerce->session;
     96        }),
     97        'wc.customer' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): \WC_Customer {
     98            return $wooCommerce->customer;
     99        }),
     100        'wc.cart' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): \WC_Cart {
     101            return $wooCommerce->cart;
     102        }),
     103        'wc.currency' => new Factory(['wc'], static function (): string {
     104            return get_woocommerce_currency();
     105        }),
     106        'wc.price_decimals' => new Factory(['wc'], static function (): int {
     107            return \wc_get_price_decimals();
     108        }),
     109        'wc.settings.price_include_tax' => new Factory(['wc'], static function (): bool {
     110            return \wc_prices_include_tax();
     111        }),
     112        'wc.is_fragment_update' => new Factory([], static function (): bool {
     113            $wcAjaxAction = \filter_input(\INPUT_GET, 'wc-ajax', \FILTER_CALLBACK, ['options' => 'sanitize_text_field']);
     114            return $wcAjaxAction === 'update_order_review' || $wcAjaxAction === 'update_checkout';
     115        }),
     116        'wc.is_store_api_request' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): bool {
     117            /**
     118             * We really really wish to access raw data here.
     119             * Wea re also doing only string comparisons and will not use the data
     120             * for processing. Hence:
     121             * phpcs:disable WordPress.Security.ValidatedSanitizedInput.MissingUnslash
     122             * phpcs:disable WordPress.Security.ValidatedSanitizedInput.InputNotSanitized
     123             */
     124            global $wp_rewrite;
     125            \assert($wp_rewrite instanceof \WP_Rewrite);
     126            if ($wp_rewrite->using_permalinks()) {
     127                /**
     128                 * is_store_api_request is not available <=8.9.1.
     129                 * However, block checkout as a whole has been around far longer.
     130                 * So for older WC versions, we execute a copy of the method we have today
     131                 */
     132                if (!\method_exists($wooCommerce, 'is_store_api_request')) {
     133                    if (empty($_SERVER['REQUEST_URI'])) {
     134                        return \false;
     135                    }
     136                    // phpcs:disable WordPress.Security.ValidatedSanitizedInput.MissingUnslash, WordPress.Security.ValidatedSanitizedInput.InputNotSanitized
     137                    return \false !== \strpos($_SERVER['REQUEST_URI'], \trailingslashit(\rest_get_url_prefix()) . 'wc/store/');
    96138                }
    97                 // phpcs:disable WordPress.Security.ValidatedSanitizedInput.MissingUnslash, WordPress.Security.ValidatedSanitizedInput.InputNotSanitized
    98                 return \false !== \strpos($_SERVER['REQUEST_URI'], \trailingslashit(\rest_get_url_prefix()) . 'wc/store/');
    99             }
    100             return $wooCommerce->is_store_api_request();
    101         }
    102         return \preg_match('/\/index\.php\?rest_route=\/wc\/store\//', isset($_SERVER['REQUEST_URI']) ? \urldecode($_SERVER['REQUEST_URI']) : '') === 1;
    103         /**
    104          * phpcs:enable WordPress.Security.ValidatedSanitizedInput.MissingUnslash
    105          * phpcs:enable WordPress.Security.ValidatedSanitizedInput.InputNotSanitized
    106          */
    107     }), 'wc.is_checkout_pay_page' => new Factory(['wc'], static function (): bool {
    108         return is_checkout_pay_page();
    109     }), 'wc.is_order_received_page' => new Factory(['wc'], static function (): bool {
    110         return is_order_received_page();
    111     }), 'wc.order_under_payment' => new Factory(['wc.order_awaiting_payment', 'wc.pay_for_order_id'], static function (int $orderAwaitingPayment, int $payForOrderId): int {
    112         if ($payForOrderId) {
    113             return $payForOrderId;
    114         }
    115         return $orderAwaitingPayment;
    116     }), 'wc.order_awaiting_payment' => new Factory(['wc.session'], static function (\WC_Session $session): int {
    117         /** @var int|false $orderAwaitingPayment */
    118         $orderAwaitingPayment = $session->get('order_awaiting_payment');
    119         return (int) $orderAwaitingPayment;
    120     }), 'wc.pay_for_order_id' => new Factory(['wc'], static function (): int {
    121         return (int) \get_query_var('order-pay');
    122     }), 'wc.order_item_types_for_product' => new Factory([], static function (): array {
    123         return ['line_item', 'shipping', 'fee', 'coupon'];
    124     }), 'wc.ajax_url' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): string {
    125         return $wooCommerce->ajax_url();
    126     }), 'wc.countries' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): \WC_Countries {
    127         return $wooCommerce->countries;
    128     }), 'wc.shop_url' => new Factory([], static function (): string {
    129         return (string) \get_permalink(\wc_get_page_id('shop'));
    130     }), 'wc.admin_permission' => new Value('manage_woocommerce'), 'wc.hpos.is_enabled' => static function (): bool {
    131         if (!\method_exists(OrderUtil::class, 'custom_orders_table_usage_is_enabled')) {
    132             return \false;
    133         }
    134         /**
    135          * @psalm-var mixed $enabled
    136          */
    137         $enabled = OrderUtil::custom_orders_table_usage_is_enabled();
    138         //WooCommerce return types sometimes incorrect, better to make sure.
    139         return \is_bool($enabled) ? $enabled : \wc_string_to_bool((string) $enabled);
    140     }, 'wc.is_block_checkout' => fn() => \function_exists('has_block') && \has_block('woocommerce/checkout')];
     139                return $wooCommerce->is_store_api_request();
     140            }
     141            return \preg_match('/\/index\.php\?rest_route=\/wc\/store\//', isset($_SERVER['REQUEST_URI']) ? \urldecode($_SERVER['REQUEST_URI']) : '') === 1;
     142            /**
     143             * phpcs:enable WordPress.Security.ValidatedSanitizedInput.MissingUnslash
     144             * phpcs:enable WordPress.Security.ValidatedSanitizedInput.InputNotSanitized
     145             */
     146        }),
     147        'wc.order_awaiting_payment' => new Factory(['wc.session'], static function (\WC_Session $session): int {
     148            /** @var int|false $orderAwaitingPayment */
     149            $orderAwaitingPayment = $session->get('order_awaiting_payment');
     150            return (int) $orderAwaitingPayment;
     151        }),
     152        'wc.pay_for_order_id.from_header' => new Factory([], static function (): int {
     153            /**
     154             * When using the Store API we currently rely on custom HHT header to pass
     155             * information about the current checkout attempt.
     156             *
     157             * @todo: deal with the code duplication. Currently, we have the same logic
     158             *      for determining context in ListSessionManager. As we may get
     159             *      rid of contexts soon, I'm leaving it as is so far.
     160             */
     161            $headerUtil = new RequestHeaderUtil();
     162            $paymentCheckoutHeader = 'x-payoneer-is-payment-checkout';
     163            $orderKey = $headerUtil->getHeader($paymentCheckoutHeader);
     164            if (!empty($orderKey)) {
     165                return (int) \wc_get_order_id_by_order_key($orderKey);
     166            }
     167            return 0;
     168        }),
     169        'wc.order_item_types_for_product' => new Factory([], static function (): array {
     170            return ['line_item', 'shipping', 'fee', 'coupon'];
     171        }),
     172        'wc.ajax_url' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): string {
     173            return $wooCommerce->ajax_url();
     174        }),
     175        'wc.countries' => new Factory(['wc'], static function (\WooCommerce $wooCommerce): \WC_Countries {
     176            return $wooCommerce->countries;
     177        }),
     178        'wc.shop_url' => new Factory([], static function (): string {
     179            return (string) \get_permalink(\wc_get_page_id('shop'));
     180        }),
     181        'wc.admin_permission' => new Value('manage_woocommerce'),
     182        'wc.hpos.is_enabled' => static function (): bool {
     183            if (!\method_exists(OrderUtil::class, 'custom_orders_table_usage_is_enabled')) {
     184                return \false;
     185            }
     186            /**
     187             * @psalm-var mixed $enabled
     188             */
     189            $enabled = OrderUtil::custom_orders_table_usage_is_enabled();
     190            //WooCommerce return types sometimes incorrect, better to make sure.
     191            return \is_bool($enabled) ? $enabled : \wc_string_to_bool((string) $enabled);
     192        },
     193        'wc.is_block_checkout' => fn() => \function_exists('has_block') && \has_block('woocommerce/checkout'),
     194        /** Order finder */
     195        'wp.order_finder' => static function (ContainerInterface $container): OrderFinderInterface {
     196            $transactionIdFieldName = (string) $container->get('webhooks.order.transaction_id_field_name');
     197            $hposEnabled = (bool) $container->get('wc.hpos.is_enabled');
     198            return $hposEnabled ? new HposOrderFinder($transactionIdFieldName) : new OrderFinder($transactionIdFieldName);
     199        },
     200        'wp.add_transaction_id_field_support' => new Constructor(AddTransactionIdFieldSupport::class, ['webhooks.order.transaction_id_field_name']),
     201        'wp.refund_finder' => new Constructor(RefundFinder::class, ['webhooks.order_refund.payout_id_field_name']),
     202        'wp.add_payout_id_field_support' => new Constructor(AddPayoutIdFieldSupport::class, ['webhooks.order_refund.payout_id_field_name']),
     203    ];
    141204};
  • payoneer-checkout/trunk/modules/inpsyde/payoneer-wp/src/WpModule.php

    r3111876 r3321269  
    44namespace Syde\Vendor\Inpsyde\PayoneerForWoocommerce\Wp;
    55
     6use Syde\Vendor\Inpsyde\Modularity\Module\ExecutableModule;
    67use Syde\Vendor\Inpsyde\Modularity\Module\FactoryModule;
    78use Syde\Vendor\Inpsyde\Modularity\Module\ServiceModule;
     
    1011 * The WP core features module.
    1112 */
    12 class WpModule implements ServiceModule, FactoryModule
     13class WpModule implements ServiceModule, FactoryModule, ExecutableModule
    1314{
    1415    /**
     
    4647        return $this->factories;
    4748    }
     49    public function run(ContainerInterface $container): bool
     50    {
     51        /** @var callable():void $addTransactionIdFieldSupport */
     52        $addTransactionIdFieldSupport = $container->get('wp.add_transaction_id_field_support');
     53        $addTransactionIdFieldSupport();
     54        /** @var callable():void $addPayoutIdFieldSupport */
     55        $addPayoutIdFieldSupport = $container->get('wp.add_payout_id_field_support');
     56        $addPayoutIdFieldSupport();
     57        return \true;
     58    }
    4859}
  • payoneer-checkout/trunk/payoneer-checkout.php

    r3305047 r3321269  
    44 * Plugin Name: Payoneer Checkout
    55 * Description: Payoneer Checkout for WooCommerce
    6  * Version: 3.3.2
     6 * Version: 3.4.0
    77 * Author:      Payoneer
    88 * Requires at least: 5.4
    99 * Tested up to: 6.8.1
    1010 * WC requires at least: 5.0
    11  * WC tested up to: 9.8.5
     11 * WC tested up to: 9.9.4
    1212 * Requires PHP: 7.4
    1313 * Author URI:  https://www.payoneer.com/
     
    1515 * Text Domain: payoneer-checkout
    1616 * Domain Path: /languages
    17  * SHA: c3df2a6bd5c2faed6d9174a79708db2f25e6284a
     17 * SHA: 6c1baa930ce70151a2d5664830e77b82cabc9a3b
    1818 */
    1919declare (strict_types=1);
  • payoneer-checkout/trunk/vendor/autoload.php

    r3305047 r3321269  
    2020require_once __DIR__ . '/composer/autoload_real.php';
    2121
    22 return ComposerAutoloaderInit110142e4fa6f6a2d282d7cc0c0e60c1d::getLoader();
     22return ComposerAutoloaderInitc969959659ee1e06936dad4bf64e751f::getLoader();
  • payoneer-checkout/trunk/vendor/composer/autoload_classmap.php

    r3305047 r3321269  
    377377    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\AbstractContext' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/AbstractContext.php',
    378378    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ApiListSessionProvider' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/ApiListSessionProvider.php',
    379     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\CheckoutContext' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/CheckoutContext.php',
    380379    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ContextInterface' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/ContextInterface.php',
    381380    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionManager' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionManager.php',
    382381    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionManagerProxy' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionManagerProxy.php',
    383382    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionMiddleware' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionMiddleware.php',
    384     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionPersistor' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionPersistor.php',
    385     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionPersistorMiddleware' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionPersistorMiddleware.php',
    386383    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionProvider' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionProvider.php',
    387384    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionProviderMiddleware' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionProviderMiddleware.php',
    388     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\NoopListSessionPersistor' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/NoopListSessionPersistor.php',
    389385    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\PaymentContext' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/PaymentContext.php',
    390386    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\Runner' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/ListSession/Runner.php',
     387    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\FetchingMiddleware' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/Middleware/FetchingMiddleware.php',
     388    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\IsProcessingTrait' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/Middleware/IsProcessingTrait.php',
     389    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\ListCache' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/Middleware/ListCache.php',
     390    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\ListCacheInterface' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/Middleware/ListCacheInterface.php',
    391391    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\UpdatingMiddleware' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/Middleware/UpdatingMiddleware.php',
    392     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\ValidatingMiddleware' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/Middleware/ValidatingMiddleware.php',
    393     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\WcOrderMiddleware' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/Middleware/WcOrderMiddleware.php',
    394     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\WcSessionMiddleware' => $baseDir . '/modules/inpsyde/payoneer-list-session/src/Middleware/WcSessionMiddleware.php',
    395392    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Migration\\MigrationModule' => $baseDir . '/modules/inpsyde/payoneer-migrator/src/MigrationModule.php',
    396393    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Migration\\Migrator' => $baseDir . '/modules/inpsyde/payoneer-migrator/src/Migrator.php',
     
    436433    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Settings\\Merchant\\SaveMerchantCommandInterface' => $baseDir . '/modules/inpsyde/payoneer-settings/src/Merchant/SaveMerchantCommandInterface.php',
    437434    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Settings\\SettingsModule' => $baseDir . '/modules/inpsyde/payoneer-settings/src/SettingsModule.php',
     435    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\LogCollector\\DbLogCollector' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Data/LogCollector/DbLogCollector.php',
     436    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\LogCollector\\FileLogCollector' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Data/LogCollector/FileLogCollector.php',
     437    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\LogCollector\\LegacyFileLogCollector' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Data/LogCollector/LegacyFileLogCollector.php',
     438    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\LogCollector\\LogCollectorFactory' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Data/LogCollector/LogCollectorFactory.php',
     439    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\LogCollector\\LogCollectorInterface' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Data/LogCollector/LogCollectorInterface.php',
     440    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\SystemReportCollector' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Data/SystemReportCollector.php',
     441    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\SystemReportCollectorInterface' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Data/SystemReportCollectorInterface.php',
     442    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\SystemReportDataDTO' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Data/SystemReportDataDTO.php',
     443    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\SystemReportParamsDTO' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Data/SystemReportParamsDTO.php',
     444    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Email\\SystemReportEmailSender' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Email/SystemReportEmailSender.php',
     445    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Email\\SystemReportEmailSenderInterface' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Email/SystemReportEmailSenderInterface.php',
     446    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Email\\SystemReportFormatter' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Email/SystemReportFormatter.php',
     447    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Email\\SystemReportFormatterInterface' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Email/SystemReportFormatterInterface.php',
     448    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Endpoint\\SystemReportEndpointController' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Endpoint/SystemReportEndpointController.php',
     449    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Permission\\SystemReportPermissionHandler' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Permission/SystemReportPermissionHandler.php',
    438450    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Renderer' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/Renderer.php',
    439451    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\StatusReportModule' => $baseDir . '/modules/inpsyde/payoneer-status-report/src/StatusReportModule.php',
     
    448460    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\Controller\\WpRestApiControllerInterface' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/Controller/WpRestApiControllerInterface.php',
    449461    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\LogIncomingWebhookRequest' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/LogIncomingWebhookRequest.php',
    450     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderFinder\\AbstractOrderFinder' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/OrderFinder/AbstractOrderFinder.php',
    451     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderFinder\\AddTransactionIdFieldSupport' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/OrderFinder/AddTransactionIdFieldSupport.php',
    452     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderFinder\\HposOrderFinder' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/OrderFinder/HposOrderFinder.php',
    453     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderFinder\\OrderFinder' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/OrderFinder/OrderFinder.php',
    454     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderFinder\\OrderFinderInterface' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/OrderFinder/OrderFinderInterface.php',
    455462    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderPaymentWebhookHandler\\ChargeBackPaymentHandler' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/OrderPaymentWebhookHandler/ChargeBackPaymentHandler.php',
    456463    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderPaymentWebhookHandler\\ChargedPaymentHandler' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/OrderPaymentWebhookHandler/ChargedPaymentHandler.php',
     
    461468    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderWebhookFinder\\OrderWebhookFinder' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/OrderWebhookFinder/OrderWebhookFinder.php',
    462469    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderWebhookFinder\\OrderWebhookFinderInterface' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/OrderWebhookFinder/OrderWebhookFinderInterface.php',
    463     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\RefundFinder\\AddPayoutIdFieldSupport' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/RefundFinder/AddPayoutIdFieldSupport.php',
    464     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\RefundFinder\\RefundFinder' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/RefundFinder/RefundFinder.php',
    465     'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\RefundFinder\\RefundFinderInterface' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/RefundFinder/RefundFinderInterface.php',
    466470    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\WebhookEntities' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/WebhookEntities.php',
    467471    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\WebhooksModule' => $baseDir . '/modules/inpsyde/payoneer-webhooks/src/WebhooksModule.php',
    468472    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\LocaleProviderInterface' => $baseDir . '/modules/inpsyde/payoneer-wp/src/LocaleProviderInterface.php',
    469473    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\NormalizingLocaleProviderISO639ISO3166' => $baseDir . '/modules/inpsyde/payoneer-wp/src/NormalizingLocaleProviderISO639ISO3166.php',
     474    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\OrderFinder\\AbstractOrderFinder' => $baseDir . '/modules/inpsyde/payoneer-wp/src/OrderFinder/AbstractOrderFinder.php',
     475    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\OrderFinder\\AddTransactionIdFieldSupport' => $baseDir . '/modules/inpsyde/payoneer-wp/src/OrderFinder/AddTransactionIdFieldSupport.php',
     476    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\OrderFinder\\HposOrderFinder' => $baseDir . '/modules/inpsyde/payoneer-wp/src/OrderFinder/HposOrderFinder.php',
     477    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\OrderFinder\\OrderFinder' => $baseDir . '/modules/inpsyde/payoneer-wp/src/OrderFinder/OrderFinder.php',
     478    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\OrderFinder\\OrderFinderInterface' => $baseDir . '/modules/inpsyde/payoneer-wp/src/OrderFinder/OrderFinderInterface.php',
     479    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\RefundFinder\\AddPayoutIdFieldSupport' => $baseDir . '/modules/inpsyde/payoneer-wp/src/RefundFinder/AddPayoutIdFieldSupport.php',
     480    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\RefundFinder\\RefundFinder' => $baseDir . '/modules/inpsyde/payoneer-wp/src/RefundFinder/RefundFinder.php',
     481    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\RefundFinder\\RefundFinderInterface' => $baseDir . '/modules/inpsyde/payoneer-wp/src/RefundFinder/RefundFinderInterface.php',
    470482    'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\WpModule' => $baseDir . '/modules/inpsyde/payoneer-wp/src/WpModule.php',
    471483    'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\ApiException' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/ApiException.php',
     
    591603    'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\Phone\\PhoneSerializer' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/Phone/PhoneSerializer.php',
    592604    'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\Phone\\PhoneSerializerInterface' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/Phone/PhoneSerializerInterface.php',
    593     'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModel' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModel.php',
    594     'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelDeserializer' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelDeserializer.php',
    595     'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelDeserializerInterface' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelDeserializerInterface.php',
    596     'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelFactory' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelFactory.php',
    597     'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelFactoryInterface' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelFactoryInterface.php',
    598     'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelInterface' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelInterface.php',
    599     'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelSerializer' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelSerializer.php',
    600     'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelSerializerInterface' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelSerializerInterface.php',
    601605    'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\Product\\Product' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/Product/Product.php',
    602606    'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\Product\\ProductDeserializer' => $baseDir . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/Product/ProductDeserializer.php',
  • payoneer-checkout/trunk/vendor/composer/autoload_real.php

    r3305047 r3321269  
    33// autoload_real.php @generated by Composer
    44
    5 class ComposerAutoloaderInit110142e4fa6f6a2d282d7cc0c0e60c1d
     5class ComposerAutoloaderInitc969959659ee1e06936dad4bf64e751f
    66{
    77    private static $loader;
     
    2525        require __DIR__ . '/platform_check.php';
    2626
    27         spl_autoload_register(array('ComposerAutoloaderInit110142e4fa6f6a2d282d7cc0c0e60c1d', 'loadClassLoader'), true, true);
     27        spl_autoload_register(array('ComposerAutoloaderInitc969959659ee1e06936dad4bf64e751f', 'loadClassLoader'), true, true);
    2828        self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
    29         spl_autoload_unregister(array('ComposerAutoloaderInit110142e4fa6f6a2d282d7cc0c0e60c1d', 'loadClassLoader'));
     29        spl_autoload_unregister(array('ComposerAutoloaderInitc969959659ee1e06936dad4bf64e751f', 'loadClassLoader'));
    3030
    3131        require __DIR__ . '/autoload_static.php';
    32         call_user_func(\Composer\Autoload\ComposerStaticInit110142e4fa6f6a2d282d7cc0c0e60c1d::getInitializer($loader));
     32        call_user_func(\Composer\Autoload\ComposerStaticInitc969959659ee1e06936dad4bf64e751f::getInitializer($loader));
    3333
    3434        $loader->register(true);
    3535
    36         $filesToLoad = \Composer\Autoload\ComposerStaticInit110142e4fa6f6a2d282d7cc0c0e60c1d::$files;
     36        $filesToLoad = \Composer\Autoload\ComposerStaticInitc969959659ee1e06936dad4bf64e751f::$files;
    3737        $requireFile = \Closure::bind(static function ($fileIdentifier, $file) {
    38             if (empty($GLOBALS['__composer_autoload_files_c3df2a6bd5c2faed6d9174a79708db2f25e6284a'][$fileIdentifier])) {
    39                 $GLOBALS['__composer_autoload_files_c3df2a6bd5c2faed6d9174a79708db2f25e6284a'][$fileIdentifier] = true;
     38            if (empty($GLOBALS['__composer_autoload_files_6c1baa930ce70151a2d5664830e77b82cabc9a3b'][$fileIdentifier])) {
     39                $GLOBALS['__composer_autoload_files_6c1baa930ce70151a2d5664830e77b82cabc9a3b'][$fileIdentifier] = true;
    4040
    4141                require $file;
  • payoneer-checkout/trunk/vendor/composer/autoload_static.php

    r3305047 r3321269  
    55namespace Composer\Autoload;
    66
    7 class ComposerStaticInit110142e4fa6f6a2d282d7cc0c0e60c1d
     7class ComposerStaticInitc969959659ee1e06936dad4bf64e751f
    88{
    99    public static $files = array (
     
    611611        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\AbstractContext' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/AbstractContext.php',
    612612        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ApiListSessionProvider' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/ApiListSessionProvider.php',
    613         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\CheckoutContext' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/CheckoutContext.php',
    614613        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ContextInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/ContextInterface.php',
    615614        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionManager' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionManager.php',
    616615        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionManagerProxy' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionManagerProxy.php',
    617616        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionMiddleware' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionMiddleware.php',
    618         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionPersistor' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionPersistor.php',
    619         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionPersistorMiddleware' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionPersistorMiddleware.php',
    620617        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionProvider' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionProvider.php',
    621618        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\ListSessionProviderMiddleware' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/ListSessionProviderMiddleware.php',
    622         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\NoopListSessionPersistor' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/NoopListSessionPersistor.php',
    623619        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\PaymentContext' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/PaymentContext.php',
    624620        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\ListSession\\Runner' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/ListSession/Runner.php',
     621        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\FetchingMiddleware' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/Middleware/FetchingMiddleware.php',
     622        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\IsProcessingTrait' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/Middleware/IsProcessingTrait.php',
     623        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\ListCache' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/Middleware/ListCache.php',
     624        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\ListCacheInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/Middleware/ListCacheInterface.php',
    625625        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\UpdatingMiddleware' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/Middleware/UpdatingMiddleware.php',
    626         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\ValidatingMiddleware' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/Middleware/ValidatingMiddleware.php',
    627         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\WcOrderMiddleware' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/Middleware/WcOrderMiddleware.php',
    628         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\ListSession\\Middleware\\WcSessionMiddleware' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-list-session/src/Middleware/WcSessionMiddleware.php',
    629626        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Migration\\MigrationModule' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-migrator/src/MigrationModule.php',
    630627        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Migration\\Migrator' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-migrator/src/Migrator.php',
     
    670667        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Settings\\Merchant\\SaveMerchantCommandInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-settings/src/Merchant/SaveMerchantCommandInterface.php',
    671668        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Settings\\SettingsModule' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-settings/src/SettingsModule.php',
     669        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\LogCollector\\DbLogCollector' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Data/LogCollector/DbLogCollector.php',
     670        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\LogCollector\\FileLogCollector' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Data/LogCollector/FileLogCollector.php',
     671        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\LogCollector\\LegacyFileLogCollector' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Data/LogCollector/LegacyFileLogCollector.php',
     672        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\LogCollector\\LogCollectorFactory' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Data/LogCollector/LogCollectorFactory.php',
     673        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\LogCollector\\LogCollectorInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Data/LogCollector/LogCollectorInterface.php',
     674        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\SystemReportCollector' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Data/SystemReportCollector.php',
     675        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\SystemReportCollectorInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Data/SystemReportCollectorInterface.php',
     676        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\SystemReportDataDTO' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Data/SystemReportDataDTO.php',
     677        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Data\\SystemReportParamsDTO' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Data/SystemReportParamsDTO.php',
     678        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Email\\SystemReportEmailSender' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Email/SystemReportEmailSender.php',
     679        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Email\\SystemReportEmailSenderInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Email/SystemReportEmailSenderInterface.php',
     680        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Email\\SystemReportFormatter' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Email/SystemReportFormatter.php',
     681        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Email\\SystemReportFormatterInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Email/SystemReportFormatterInterface.php',
     682        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Endpoint\\SystemReportEndpointController' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Endpoint/SystemReportEndpointController.php',
     683        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Permission\\SystemReportPermissionHandler' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Permission/SystemReportPermissionHandler.php',
    672684        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\Renderer' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/Renderer.php',
    673685        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\StatusReport\\StatusReportModule' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-status-report/src/StatusReportModule.php',
     
    682694        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\Controller\\WpRestApiControllerInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/Controller/WpRestApiControllerInterface.php',
    683695        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\LogIncomingWebhookRequest' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/LogIncomingWebhookRequest.php',
    684         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderFinder\\AbstractOrderFinder' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/OrderFinder/AbstractOrderFinder.php',
    685         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderFinder\\AddTransactionIdFieldSupport' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/OrderFinder/AddTransactionIdFieldSupport.php',
    686         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderFinder\\HposOrderFinder' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/OrderFinder/HposOrderFinder.php',
    687         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderFinder\\OrderFinder' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/OrderFinder/OrderFinder.php',
    688         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderFinder\\OrderFinderInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/OrderFinder/OrderFinderInterface.php',
    689696        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderPaymentWebhookHandler\\ChargeBackPaymentHandler' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/OrderPaymentWebhookHandler/ChargeBackPaymentHandler.php',
    690697        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderPaymentWebhookHandler\\ChargedPaymentHandler' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/OrderPaymentWebhookHandler/ChargedPaymentHandler.php',
     
    695702        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderWebhookFinder\\OrderWebhookFinder' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/OrderWebhookFinder/OrderWebhookFinder.php',
    696703        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\OrderWebhookFinder\\OrderWebhookFinderInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/OrderWebhookFinder/OrderWebhookFinderInterface.php',
    697         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\RefundFinder\\AddPayoutIdFieldSupport' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/RefundFinder/AddPayoutIdFieldSupport.php',
    698         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\RefundFinder\\RefundFinder' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/RefundFinder/RefundFinder.php',
    699         'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\RefundFinder\\RefundFinderInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/RefundFinder/RefundFinderInterface.php',
    700704        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\WebhookEntities' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/WebhookEntities.php',
    701705        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Webhooks\\WebhooksModule' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-webhooks/src/WebhooksModule.php',
    702706        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\LocaleProviderInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/LocaleProviderInterface.php',
    703707        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\NormalizingLocaleProviderISO639ISO3166' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/NormalizingLocaleProviderISO639ISO3166.php',
     708        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\OrderFinder\\AbstractOrderFinder' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/OrderFinder/AbstractOrderFinder.php',
     709        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\OrderFinder\\AddTransactionIdFieldSupport' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/OrderFinder/AddTransactionIdFieldSupport.php',
     710        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\OrderFinder\\HposOrderFinder' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/OrderFinder/HposOrderFinder.php',
     711        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\OrderFinder\\OrderFinder' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/OrderFinder/OrderFinder.php',
     712        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\OrderFinder\\OrderFinderInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/OrderFinder/OrderFinderInterface.php',
     713        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\RefundFinder\\AddPayoutIdFieldSupport' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/RefundFinder/AddPayoutIdFieldSupport.php',
     714        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\RefundFinder\\RefundFinder' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/RefundFinder/RefundFinder.php',
     715        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\RefundFinder\\RefundFinderInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/RefundFinder/RefundFinderInterface.php',
    704716        'Syde\\Vendor\\Inpsyde\\PayoneerForWoocommerce\\Wp\\WpModule' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-wp/src/WpModule.php',
    705717        'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\ApiException' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/ApiException.php',
     
    825837        'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\Phone\\PhoneSerializer' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/Phone/PhoneSerializer.php',
    826838        'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\Phone\\PhoneSerializerInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/Phone/PhoneSerializerInterface.php',
    827         'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModel' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModel.php',
    828         'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelDeserializer' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelDeserializer.php',
    829         'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelDeserializerInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelDeserializerInterface.php',
    830         'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelFactory' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelFactory.php',
    831         'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelFactoryInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelFactoryInterface.php',
    832         'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelInterface.php',
    833         'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelSerializer' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelSerializer.php',
    834         'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\ProcessingModel\\ProcessingModelSerializerInterface' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/ProcessingModel/ProcessingModelSerializerInterface.php',
    835839        'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\Product\\Product' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/Product/Product.php',
    836840        'Syde\\Vendor\\Inpsyde\\PayoneerSdk\\Api\\Entities\\Product\\ProductDeserializer' => __DIR__ . '/../..' . '/modules/inpsyde/payoneer-sdk/src/Api/Entities/Product/ProductDeserializer.php',
     
    970974    {
    971975        return \Closure::bind(function () use ($loader) {
    972             $loader->prefixLengthsPsr4 = ComposerStaticInit110142e4fa6f6a2d282d7cc0c0e60c1d::$prefixLengthsPsr4;
    973             $loader->prefixDirsPsr4 = ComposerStaticInit110142e4fa6f6a2d282d7cc0c0e60c1d::$prefixDirsPsr4;
    974             $loader->classMap = ComposerStaticInit110142e4fa6f6a2d282d7cc0c0e60c1d::$classMap;
     976            $loader->prefixLengthsPsr4 = ComposerStaticInitc969959659ee1e06936dad4bf64e751f::$prefixLengthsPsr4;
     977            $loader->prefixDirsPsr4 = ComposerStaticInitc969959659ee1e06936dad4bf64e751f::$prefixDirsPsr4;
     978            $loader->classMap = ComposerStaticInitc969959659ee1e06936dad4bf64e751f::$classMap;
    975979
    976980        }, null, ClassLoader::class);
  • payoneer-checkout/trunk/vendor/composer/installed.json

    r3260742 r3321269  
    781781        {
    782782            "name": "inpsyde\/modularity",
    783             "version": "1.11.0",
    784             "version_normalized": "1.11.0.0",
     783            "version": "1.12.0",
     784            "version_normalized": "1.12.0.0",
    785785            "source": {
    786786                "type": "git",
    787787                "url": "https:\/\/github.com\/inpsyde\/modularity.git",
    788                 "reference": "c79bb3682f55e1a2ece67f36e70d04fa2ab8c65d"
     788                "reference": "e1ca1c81b7b663355906b586525d21ac5d46bc65"
    789789            },
    790790            "dist": {
    791791                "type": "zip",
    792                 "url": "https:\/\/api.github.com\/repos\/inpsyde\/modularity\/zipball\/c79bb3682f55e1a2ece67f36e70d04fa2ab8c65d",
    793                 "reference": "c79bb3682f55e1a2ece67f36e70d04fa2ab8c65d",
     792                "url": "https:\/\/api.github.com\/repos\/inpsyde\/modularity\/zipball\/e1ca1c81b7b663355906b586525d21ac5d46bc65",
     793                "reference": "e1ca1c81b7b663355906b586525d21ac5d46bc65",
    794794                "shasum": "",
    795795                "mirrors": [
     
    802802            "require": {
    803803                "ext-json": "*",
    804                 "php": ">=7.4 <8.4",
     804                "php": ">=7.4",
    805805                "psr\/container": "^1.1.0 || ^2"
    806806            },
    807807            "require-dev": {
    808808                "brain\/monkey": "^2.6.1",
    809                 "inpsyde\/php-coding-standards": "^2@dev",
    810                 "inpsyde\/wp-stubs-versions": "dev-latest",
     809                "inpsyde\/wp-stubs-versions": "6.7",
    811810                "mikey179\/vfsstream": "^v1.6.11",
     811                "phpstan\/phpstan": "^2.1.1",
     812                "phpstan\/phpstan-deprecation-rules": "^2.0.1",
     813                "phpstan\/phpstan-mockery": "^2.0.0",
     814                "phpstan\/phpstan-phpunit": "^2.0.4",
    812815                "phpunit\/phpunit": "^9.6.19",
    813                 "roots\/wordpress-no-content": "@dev",
    814                 "vimeo\/psalm": "^5.24.0"
    815             },
    816             "time": "2024-11-28T09:34:00+00:00",
     816                "swissspidy\/phpstan-no-private": "^v1.0.0",
     817                "syde\/phpcs": "^1.0.0"
     818            },
     819            "time": "2025-05-09T12:13:17+00:00",
    817820            "type": "library",
    818821            "extra": {
     
    842845            "support": {
    843846                "issues": "https:\/\/github.com\/inpsyde\/modularity\/issues",
    844                 "source": "https:\/\/github.com\/inpsyde\/modularity\/tree\/1.11.0"
     847                "source": "https:\/\/github.com\/inpsyde\/modularity\/tree\/1.12.0"
    845848            },
    846849            "install-path": "..\/inpsyde\/modularity"
     
    848851        {
    849852            "name": "inpsyde\/payment-gateway",
    850             "version": "2.4.1",
    851             "version_normalized": "2.4.1.0",
     853            "version": "2.7.1",
     854            "version_normalized": "2.7.1.0",
    852855            "source": {
    853856                "type": "git",
    854857                "url": "git@github.com:inpsyde\/payment-gateway.git",
    855                 "reference": "48be2bbdb6c0056d587cc13b65acc375cb40ad32"
     858                "reference": "00260a21acbe2614e9ddcef5e0182b4dbbb3011b"
    856859            },
    857860            "dist": {
    858861                "type": "zip",
    859                 "url": "https:\/\/api.github.com\/repos\/inpsyde\/payment-gateway\/zipball\/48be2bbdb6c0056d587cc13b65acc375cb40ad32",
    860                 "reference": "48be2bbdb6c0056d587cc13b65acc375cb40ad32",
     862                "url": "https:\/\/api.github.com\/repos\/inpsyde\/payment-gateway\/zipball\/00260a21acbe2614e9ddcef5e0182b4dbbb3011b",
     863                "reference": "00260a21acbe2614e9ddcef5e0182b4dbbb3011b",
    861864                "shasum": "",
    862865                "mirrors": [
     
    884887                "vimeo\/psalm": "^4.3"
    885888            },
    886             "time": "2025-02-26T20:08:41+00:00",
     889            "time": "2025-06-20T14:31:21+00:00",
    887890            "type": "inpsyde-module",
    888891            "extra": {
     
    973976            ],
    974977            "support": {
    975                 "source": "https:\/\/github.com\/inpsyde\/payment-gateway\/tree\/2.4.1",
     978                "source": "https:\/\/github.com\/inpsyde\/payment-gateway\/tree\/2.7.1",
    976979                "issues": "https:\/\/github.com\/inpsyde\/payment-gateway\/issues"
    977980            },
     
    980983        {
    981984            "name": "inpsyde\/payoneer-admin-banner",
    982             "version": "dev-release\/3.3.0",
    983             "version_normalized": "dev-release\/3.3.0",
     985            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     986            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    984987            "dist": {
    985988                "type": "path",
     
    10321035        {
    10331036            "name": "inpsyde\/payoneer-analytics",
    1034             "version": "dev-release\/3.3.0",
    1035             "version_normalized": "dev-release\/3.3.0",
     1037            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1038            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    10361039            "dist": {
    10371040                "type": "path",
     
    10811084        {
    10821085            "name": "inpsyde\/payoneer-api",
    1083             "version": "dev-release\/3.3.0",
    1084             "version_normalized": "dev-release\/3.3.0",
     1086            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1087            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    10851088            "dist": {
    10861089                "type": "path",
     
    11301133        {
    11311134            "name": "inpsyde\/payoneer-embedded-payment",
    1132             "version": "dev-release\/3.3.0",
    1133             "version_normalized": "dev-release\/3.3.0",
     1135            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1136            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    11341137            "dist": {
    11351138                "type": "path",
     
    11841187        {
    11851188            "name": "inpsyde\/payoneer-hosted-payment",
    1186             "version": "dev-release\/3.3.0",
    1187             "version_normalized": "dev-release\/3.3.0",
     1189            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1190            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    11881191            "dist": {
    11891192                "type": "path",
     
    12371240        {
    12381241            "name": "inpsyde\/payoneer-list-session",
    1239             "version": "dev-release\/3.3.0",
    1240             "version_normalized": "dev-release\/3.3.0",
     1242            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1243            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    12411244            "dist": {
    12421245                "type": "path",
     
    12791282        {
    12801283            "name": "inpsyde\/payoneer-migrator",
    1281             "version": "dev-release\/3.3.0",
    1282             "version_normalized": "dev-release\/3.3.0",
     1284            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1285            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    12831286            "dist": {
    12841287                "type": "path",
     
    13271330        {
    13281331            "name": "inpsyde\/payoneer-page-detector",
    1329             "version": "dev-release\/3.3.0",
    1330             "version_normalized": "dev-release\/3.3.0",
     1332            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1333            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    13311334            "dist": {
    13321335                "type": "path",
     
    13751378        {
    13761379            "name": "inpsyde\/payoneer-payment-gateway-checkout",
    1377             "version": "dev-release\/3.3.0",
    1378             "version_normalized": "dev-release\/3.3.0",
     1380            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1381            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    13791382            "dist": {
    13801383                "type": "path",
     
    14261429        {
    14271430            "name": "inpsyde\/payoneer-payment-methods",
    1428             "version": "dev-release\/3.3.0",
    1429             "version_normalized": "dev-release\/3.3.0",
     1431            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1432            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    14301433            "dist": {
    14311434                "type": "path",
     
    14771480        {
    14781481            "name": "inpsyde\/payoneer-sdk",
    1479             "version": "v3.0.1",
    1480             "version_normalized": "3.0.1.0",
     1482            "version": "v4.1.0",
     1483            "version_normalized": "4.1.0.0",
    14811484            "source": {
    14821485                "type": "git",
    14831486                "url": "git@github.com:inpsyde\/payoneer-sdk.git",
    1484                 "reference": "98b31667d643446cddd0bf3a1f623c133bef2cd0"
     1487                "reference": "096f3db439f7d77bef2d165dbecd406cc4210550"
    14851488            },
    14861489            "dist": {
    14871490                "type": "zip",
    1488                 "url": "https:\/\/api.github.com\/repos\/inpsyde\/payoneer-sdk\/zipball\/98b31667d643446cddd0bf3a1f623c133bef2cd0",
    1489                 "reference": "98b31667d643446cddd0bf3a1f623c133bef2cd0",
     1491                "url": "https:\/\/api.github.com\/repos\/inpsyde\/payoneer-sdk\/zipball\/096f3db439f7d77bef2d165dbecd406cc4210550",
     1492                "reference": "096f3db439f7d77bef2d165dbecd406cc4210550",
    14901493                "shasum": "",
    14911494                "mirrors": [
     
    15241527                "webmozart\/path-util": "^2.3@stable"
    15251528            },
    1526             "time": "2025-01-23T10:46:21+00:00",
     1529            "time": "2025-06-23T07:27:08+00:00",
    15271530            "type": "inpsyde-module",
    15281531            "installation-source": "dist",
     
    15391542            "notification-url": "https:\/\/repo.packagist.com\/inpsyde\/downloads\/",
    15401543            "license": [
    1541                 "MIT"
    1542             ],
    1543             "authors": [
    1544                 {
    1545                     "name": "Inpsyde",
    1546                     "email": "hello@inpsyde.com"
     1544                "GPL-2.0-or-later"
     1545            ],
     1546            "authors": [
     1547                {
     1548                    "name": "Syde GmbH",
     1549                    "homepage": "https:\/\/syde.com\/",
     1550                    "email": "hello@syde.com",
     1551                    "role": "Company"
    15471552                }
    15481553            ],
    15491554            "description": "Payoneer SDK module for inpsyde\/modularity.",
    15501555            "support": {
    1551                 "source": "https:\/\/github.com\/inpsyde\/payoneer-sdk\/tree\/v3.0.1",
     1556                "source": "https:\/\/github.com\/inpsyde\/payoneer-sdk\/tree\/v4.1.0",
    15521557                "issues": "https:\/\/github.com\/inpsyde\/payoneer-sdk\/issues"
    15531558            },
     
    15561561        {
    15571562            "name": "inpsyde\/payoneer-settings",
    1558             "version": "dev-release\/3.3.0",
    1559             "version_normalized": "dev-release\/3.3.0",
     1563            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1564            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    15601565            "dist": {
    15611566                "type": "path",
     
    16051610        {
    16061611            "name": "inpsyde\/payoneer-status-report",
    1607             "version": "dev-release\/3.3.0",
    1608             "version_normalized": "dev-release\/3.3.0",
     1612            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1613            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    16091614            "dist": {
    16101615                "type": "path",
     
    16521657        {
    16531658            "name": "inpsyde\/payoneer-third-party-compat",
    1654             "version": "dev-release\/3.3.0",
    1655             "version_normalized": "dev-release\/3.3.0",
     1659            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1660            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    16561661            "dist": {
    16571662                "type": "path",
     
    16921697        {
    16931698            "name": "inpsyde\/payoneer-webhooks",
    1694             "version": "dev-release\/3.3.0",
    1695             "version_normalized": "dev-release\/3.3.0",
     1699            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1700            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    16961701            "dist": {
    16971702                "type": "path",
     
    17451750        {
    17461751            "name": "inpsyde\/payoneer-websdk",
    1747             "version": "dev-release\/3.3.0",
    1748             "version_normalized": "dev-release\/3.3.0",
     1752            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1753            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    17491754            "dist": {
    17501755                "type": "path",
     
    17951800        {
    17961801            "name": "inpsyde\/payoneer-wp",
    1797             "version": "dev-release\/3.3.0",
    1798             "version_normalized": "dev-release\/3.3.0",
     1802            "version": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
     1803            "version_normalized": "dev-fix\/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site",
    17991804            "dist": {
    18001805                "type": "path",
     
    26062611        {
    26072612            "name": "sniccowp\/php-scoper-wordpress-excludes",
    2608             "version": "6.7.2",
    2609             "version_normalized": "6.7.2.0",
     2613            "version": "6.8.1",
     2614            "version_normalized": "6.8.1.0",
    26102615            "source": {
    26112616                "type": "git",
    26122617                "url": "https:\/\/github.com\/snicco\/php-scoper-wordpress-excludes.git",
    2613                 "reference": "1e65b207d6f4753904774430ccfc06cb6bfa486e"
     2618                "reference": "c2c18f89a9aa2d7ef1998d233b9ed00d0deff5dd"
    26142619            },
    26152620            "dist": {
    26162621                "type": "zip",
    2617                 "url": "https:\/\/api.github.com\/repos\/snicco\/php-scoper-wordpress-excludes\/zipball\/1e65b207d6f4753904774430ccfc06cb6bfa486e",
    2618                 "reference": "1e65b207d6f4753904774430ccfc06cb6bfa486e",
     2622                "url": "https:\/\/api.github.com\/repos\/snicco\/php-scoper-wordpress-excludes\/zipball\/c2c18f89a9aa2d7ef1998d233b9ed00d0deff5dd",
     2623                "reference": "c2c18f89a9aa2d7ef1998d233b9ed00d0deff5dd",
    26192624                "shasum": "",
    26202625                "mirrors": [
     
    26282633                "php": "^7.4",
    26292634                "php-stubs\/wordpress-globals": "0.2.0",
    2630                 "php-stubs\/wordpress-stubs": "6.7.2",
     2635                "php-stubs\/wordpress-stubs": "6.8.1",
    26312636                "sniccowp\/php-scoper-excludes": "dev-master"
    26322637            },
    2633             "time": "2025-02-06T00:29:24+00:00",
     2638            "time": "2025-05-03T00:01:53+00:00",
    26342639            "type": "library",
    26352640            "installation-source": "dist",
     
    26562661            "support": {
    26572662                "issues": "https:\/\/github.com\/snicco\/php-scoper-wordpress-excludes\/issues",
    2658                 "source": "https:\/\/github.com\/snicco\/php-scoper-wordpress-excludes\/tree\/6.7.2"
     2663                "source": "https:\/\/github.com\/snicco\/php-scoper-wordpress-excludes\/tree\/6.8.1"
    26592664            },
    26602665            "install-path": "..\/sniccowp\/php-scoper-wordpress-excludes"
     
    26622667        {
    26632668            "name": "symfony\/polyfill-php80",
    2664             "version": "v1.31.0",
    2665             "version_normalized": "1.31.0.0",
     2669            "version": "v1.32.0",
     2670            "version_normalized": "1.32.0.0",
    26662671            "source": {
    26672672                "type": "git",
    26682673                "url": "https:\/\/github.com\/symfony\/polyfill-php80.git",
    2669                 "reference": "60328e362d4c2c802a54fcbf04f9d3fb892b4cf8"
     2674                "reference": "0cc9dd0f17f61d8131e7df6b84bd344899fe2608"
    26702675            },
    26712676            "dist": {
    26722677                "type": "zip",
    2673                 "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-php80\/zipball\/60328e362d4c2c802a54fcbf04f9d3fb892b4cf8",
    2674                 "reference": "60328e362d4c2c802a54fcbf04f9d3fb892b4cf8",
     2678                "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-php80\/zipball\/0cc9dd0f17f61d8131e7df6b84bd344899fe2608",
     2679                "reference": "0cc9dd0f17f61d8131e7df6b84bd344899fe2608",
    26752680                "shasum": "",
    26762681                "mirrors": [
     
    26842689                "php": ">=7.2"
    26852690            },
    2686             "time": "2024-09-09T11:45:10+00:00",
     2691            "time": "2025-01-02T08:10:11+00:00",
    26872692            "type": "library",
    26882693            "extra": {
    26892694                "thanks": {
    2690                     "name": "symfony\/polyfill",
    2691                     "url": "https:\/\/github.com\/symfony\/polyfill"
     2695                    "url": "https:\/\/github.com\/symfony\/polyfill",
     2696                    "name": "symfony\/polyfill"
    26922697                }
    26932698            },
     
    27312736            ],
    27322737            "support": {
    2733                 "source": "https:\/\/github.com\/symfony\/polyfill-php80\/tree\/v1.31.0"
     2738                "source": "https:\/\/github.com\/symfony\/polyfill-php80\/tree\/v1.32.0"
    27342739            },
    27352740            "funding": [
  • payoneer-checkout/trunk/vendor/composer/installed.php

    r3305047 r3321269  
    33namespace Syde\Vendor;
    44
    5 return array('root' => array('name' => 'inpsyde/payoneer-checkout', 'pretty_version' => 'dev-release/3.3.2', 'version' => 'dev-release/3.3.2', 'reference' => 'c3df2a6bd5c2faed6d9174a79708db2f25e6284a', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), 'dev' => \false), 'versions' => array('composer/installers' => array('pretty_version' => 'v2.3.0', 'version' => '2.3.0.0', 'reference' => '12fb2dfe5e16183de69e784a7b84046c43d97e8e', 'type' => 'composer-plugin', 'install_path' => __DIR__ . '/./installers', 'aliases' => array(), 'dev_requirement' => \false), 'container-interop/service-provider' => array('pretty_version' => 'v0.4.1', 'version' => '0.4.1.0', 'reference' => 'e04441ca21ef03e10dce70b0af29269281eec6dc', 'type' => 'library', 'install_path' => __DIR__ . '/../container-interop/service-provider', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/collections-interface' => array('pretty_version' => 'v0.3.0', 'version' => '0.3.0.0', 'reference' => '74464a969b340d16889eacd9eadc9817f7e7f47a', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/collections-interface', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/containers' => array('pretty_version' => 'v0.1.5', 'version' => '0.1.5.0', 'reference' => '1568cb2def9dee213c5846c4618f9d6b2cebbdef', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/containers', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/package-interface' => array('pretty_version' => 'v0.1.0-alpha4', 'version' => '0.1.0.0-alpha4', 'reference' => 'bcc73f4285eead9b482dbb89662b723abf49298b', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/package-interface', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/services' => array('pretty_version' => 'v0.1.1-alpha3', 'version' => '0.1.1.0-alpha3', 'reference' => '1a17b6b2cb2fdef0c0b541c8992188d9740746ce', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/services', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/validation-interface' => array('pretty_version' => 'v0.3.0-alpha3', 'version' => '0.3.0.0-alpha3', 'reference' => '0e73c7bf3d2421ceb79331c60a9bc1b1d5eb65a6', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/validation-interface', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/validator' => array('pretty_version' => 'v0.1.0-alpha1', 'version' => '0.1.0.0-alpha1', 'reference' => 'e10fba08398e33e123ada3d5fe0d147a72525cc2', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/validator', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/versions' => array('pretty_version' => 'v0.1.0-alpha3', 'version' => '0.1.0.0-alpha3', 'reference' => '120b22b248d0b46e41bac93bf3394516c9d55730', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/versions', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/assets' => array('pretty_version' => '2.9.0', 'version' => '2.9.0.0', 'reference' => '2b2d2ac359383e24284388bf54a6ff4f122d3c67', 'type' => 'library', 'install_path' => __DIR__ . '/../inpsyde/assets', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/logger' => array('pretty_version' => 'v1.4.0', 'version' => '1.4.0.0', 'reference' => 'ea22ad6862a771239e02d2a33b4fafb095dc4e30', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/logger', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/modularity' => array('pretty_version' => '1.11.0', 'version' => '1.11.0.0', 'reference' => 'c79bb3682f55e1a2ece67f36e70d04fa2ab8c65d', 'type' => 'library', 'install_path' => __DIR__ . '/../inpsyde/modularity', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payment-gateway' => array('pretty_version' => '2.4.1', 'version' => '2.4.1.0', 'reference' => '48be2bbdb6c0056d587cc13b65acc375cb40ad32', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payment-gateway', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-admin-banner' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => '9fbfb5ad20c6f3eded0540fa088393a6f5ba01a2', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-admin-banner', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-analytics' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => 'cea259f74a42805a8c8c824975ecf7ebd4d6854c', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-analytics', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-api' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => '3141a286544a5828ba411f19187ecbc0776d1198', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-api', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-checkout' => array('pretty_version' => 'dev-release/3.3.2', 'version' => 'dev-release/3.3.2', 'reference' => 'c3df2a6bd5c2faed6d9174a79708db2f25e6284a', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-embedded-payment' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => '6ce354bfcb78e98026dc6c5b152b4e0b13af1ae0', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-embedded-payment', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-hosted-payment' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => '786b9784805e8830d240d21f8ea93bbc2a4818e3', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-hosted-payment', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-list-session' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => '76755c87c3df513673d5b74ca3877e66f07abda4', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-list-session', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-migrator' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => 'fa868f933c3e348befcfaf459735e300ca7b5350', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-migrator', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-page-detector' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => '0a3c51c69790735837a4e7884d74cd0656f6fe99', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-page-detector', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-payment-gateway-checkout' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => '9db2a7daa57ba440f50de2e0345faa3d8db5babe', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-payment-gateway-checkout', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-payment-methods' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => '5ce35ddeeb2f88faea898b97d6ebc2988874eb84', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-payment-methods', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-sdk' => array('pretty_version' => 'v3.0.1', 'version' => '3.0.1.0', 'reference' => '98b31667d643446cddd0bf3a1f623c133bef2cd0', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-sdk', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-settings' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => 'cb601f00438927dad370ce92c403744c8fa35cf7', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-settings', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-status-report' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => '78bc7cf91e905f1d99ca13478d4af2842796c328', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-status-report', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-third-party-compat' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => 'cd3262cd2bac6f6d5b253abf0edda9051a1cedd5', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-third-party-compat', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-webhooks' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => '3e8c63f9a746abfc79234e7ad85d4e58790b6276', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-webhooks', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-websdk' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => 'fd04181b18ca9ef28d66c267bcbcbe1991105e07', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-websdk', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-wp' => array('pretty_version' => 'dev-release/3.3.0', 'version' => 'dev-release/3.3.0', 'reference' => 'f6967b69c11ee362a2c20e7c240f4fe5f2cf5d0f', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-wp', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/psr-18-wp-http-client' => array('pretty_version' => 'v0.1.0-alpha4', 'version' => '0.1.0.0-alpha4', 'reference' => '8dd172262c95fc3fb4716b14a54c9406254ba441', 'type' => 'library', 'install_path' => __DIR__ . '/../inpsyde/psr-18-wp-http-client', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/wp-context' => array('pretty_version' => '1.5.1', 'version' => '1.5.1.0', 'reference' => '1350ada72517f5d374bff9409b4ea5a02377ec1a', 'type' => 'library', 'install_path' => __DIR__ . '/../inpsyde/wp-context', 'aliases' => array(), 'dev_requirement' => \false), 'nyholm/psr7' => array('pretty_version' => '1.8.2', 'version' => '1.8.2.0', 'reference' => 'a71f2b11690f4b24d099d6b16690a90ae14fc6f3', 'type' => 'library', 'install_path' => __DIR__ . '/../nyholm/psr7', 'aliases' => array(), 'dev_requirement' => \false), 'oomphinc/composer-installers-extender' => array('pretty_version' => '2.0.1', 'version' => '2.0.1.0', 'reference' => 'cbf4b6f9a24153b785d09eee755b995ba87bd5f9', 'type' => 'composer-plugin', 'install_path' => __DIR__ . '/../oomphinc/composer-installers-extender', 'aliases' => array(), 'dev_requirement' => \false), 'php-http/message-factory-implementation' => array('dev_requirement' => \false, 'provided' => array(0 => '1.0')), 'psr/container' => array('pretty_version' => '1.1.2', 'version' => '1.1.2.0', 'reference' => '513e0666f7216c7459170d56df27dfcefe1689ea', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/container', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-client' => array('pretty_version' => '1.0.3', 'version' => '1.0.3.0', 'reference' => 'bb5906edc1c324c9a05aa0873d40117941e5fa90', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-client', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-client-implementation' => array('dev_requirement' => \false, 'provided' => array(0 => '^1.0')), 'psr/http-factory' => array('pretty_version' => '1.1.0', 'version' => '1.1.0.0', 'reference' => '2b4765fddfe3b508ac62f829e852b1501d3f6e8a', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-factory', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-factory-implementation' => array('dev_requirement' => \false, 'provided' => array(0 => '1.0')), 'psr/http-message' => array('pretty_version' => '1.1', 'version' => '1.1.0.0', 'reference' => 'cb6ce4845ce34a8ad9e68117c10ee90a29919eba', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-message', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-message-implementation' => array('dev_requirement' => \false, 'provided' => array(0 => '1.0')), 'psr/http-server-handler' => array('pretty_version' => '1.0.2', 'version' => '1.0.2.0', 'reference' => '84c4fb66179be4caaf8e97bd239203245302e7d4', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-server-handler', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-server-middleware' => array('pretty_version' => '1.0.2', 'version' => '1.0.2.0', 'reference' => 'c1481f747daaa6a0782775cd6a8c26a1bf4a3829', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-server-middleware', 'aliases' => array(), 'dev_requirement' => \false), 'psr/log' => array('pretty_version' => '1.1.4', 'version' => '1.1.4.0', 'reference' => 'd49695b909c3b7628b6289db5479a1c204601f11', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/log', 'aliases' => array(), 'dev_requirement' => \false), 'sniccowp/php-scoper-wordpress-excludes' => array('pretty_version' => '6.7.2', 'version' => '6.7.2.0', 'reference' => '1e65b207d6f4753904774430ccfc06cb6bfa486e', 'type' => 'library', 'install_path' => __DIR__ . '/../sniccowp/php-scoper-wordpress-excludes', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/polyfill-php80' => array('pretty_version' => 'v1.31.0', 'version' => '1.31.0.0', 'reference' => '60328e362d4c2c802a54fcbf04f9d3fb892b4cf8', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-php80', 'aliases' => array(), 'dev_requirement' => \false), 'wp-oop/containers' => array('pretty_version' => 'v0.1.1-alpha3', 'version' => '0.1.1.0-alpha3', 'reference' => '01f52a9bb347e28aa25e80bd777d6e8b56451d9e', 'type' => 'library', 'install_path' => __DIR__ . '/../wp-oop/containers', 'aliases' => array(), 'dev_requirement' => \false)));
     5return array('root' => array('name' => 'inpsyde/payoneer-checkout', 'pretty_version' => 'dev-release/3.4.0', 'version' => 'dev-release/3.4.0', 'reference' => '6c1baa930ce70151a2d5664830e77b82cabc9a3b', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), 'dev' => \false), 'versions' => array('composer/installers' => array('pretty_version' => 'v2.3.0', 'version' => '2.3.0.0', 'reference' => '12fb2dfe5e16183de69e784a7b84046c43d97e8e', 'type' => 'composer-plugin', 'install_path' => __DIR__ . '/./installers', 'aliases' => array(), 'dev_requirement' => \false), 'container-interop/service-provider' => array('pretty_version' => 'v0.4.1', 'version' => '0.4.1.0', 'reference' => 'e04441ca21ef03e10dce70b0af29269281eec6dc', 'type' => 'library', 'install_path' => __DIR__ . '/../container-interop/service-provider', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/collections-interface' => array('pretty_version' => 'v0.3.0', 'version' => '0.3.0.0', 'reference' => '74464a969b340d16889eacd9eadc9817f7e7f47a', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/collections-interface', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/containers' => array('pretty_version' => 'v0.1.5', 'version' => '0.1.5.0', 'reference' => '1568cb2def9dee213c5846c4618f9d6b2cebbdef', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/containers', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/package-interface' => array('pretty_version' => 'v0.1.0-alpha4', 'version' => '0.1.0.0-alpha4', 'reference' => 'bcc73f4285eead9b482dbb89662b723abf49298b', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/package-interface', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/services' => array('pretty_version' => 'v0.1.1-alpha3', 'version' => '0.1.1.0-alpha3', 'reference' => '1a17b6b2cb2fdef0c0b541c8992188d9740746ce', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/services', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/validation-interface' => array('pretty_version' => 'v0.3.0-alpha3', 'version' => '0.3.0.0-alpha3', 'reference' => '0e73c7bf3d2421ceb79331c60a9bc1b1d5eb65a6', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/validation-interface', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/validator' => array('pretty_version' => 'v0.1.0-alpha1', 'version' => '0.1.0.0-alpha1', 'reference' => 'e10fba08398e33e123ada3d5fe0d147a72525cc2', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/validator', 'aliases' => array(), 'dev_requirement' => \false), 'dhii/versions' => array('pretty_version' => 'v0.1.0-alpha3', 'version' => '0.1.0.0-alpha3', 'reference' => '120b22b248d0b46e41bac93bf3394516c9d55730', 'type' => 'library', 'install_path' => __DIR__ . '/../dhii/versions', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/assets' => array('pretty_version' => '2.9.0', 'version' => '2.9.0.0', 'reference' => '2b2d2ac359383e24284388bf54a6ff4f122d3c67', 'type' => 'library', 'install_path' => __DIR__ . '/../inpsyde/assets', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/logger' => array('pretty_version' => 'v1.4.0', 'version' => '1.4.0.0', 'reference' => 'ea22ad6862a771239e02d2a33b4fafb095dc4e30', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/logger', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/modularity' => array('pretty_version' => '1.12.0', 'version' => '1.12.0.0', 'reference' => 'e1ca1c81b7b663355906b586525d21ac5d46bc65', 'type' => 'library', 'install_path' => __DIR__ . '/../inpsyde/modularity', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payment-gateway' => array('pretty_version' => '2.7.1', 'version' => '2.7.1.0', 'reference' => '00260a21acbe2614e9ddcef5e0182b4dbbb3011b', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payment-gateway', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-admin-banner' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => '9fbfb5ad20c6f3eded0540fa088393a6f5ba01a2', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-admin-banner', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-analytics' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => 'cea259f74a42805a8c8c824975ecf7ebd4d6854c', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-analytics', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-api' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => '3141a286544a5828ba411f19187ecbc0776d1198', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-api', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-checkout' => array('pretty_version' => 'dev-release/3.4.0', 'version' => 'dev-release/3.4.0', 'reference' => '6c1baa930ce70151a2d5664830e77b82cabc9a3b', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-embedded-payment' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => '6ce354bfcb78e98026dc6c5b152b4e0b13af1ae0', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-embedded-payment', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-hosted-payment' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => '786b9784805e8830d240d21f8ea93bbc2a4818e3', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-hosted-payment', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-list-session' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => '76755c87c3df513673d5b74ca3877e66f07abda4', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-list-session', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-migrator' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => 'fa868f933c3e348befcfaf459735e300ca7b5350', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-migrator', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-page-detector' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => '0a3c51c69790735837a4e7884d74cd0656f6fe99', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-page-detector', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-payment-gateway-checkout' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => '9db2a7daa57ba440f50de2e0345faa3d8db5babe', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-payment-gateway-checkout', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-payment-methods' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => '5ce35ddeeb2f88faea898b97d6ebc2988874eb84', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-payment-methods', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-sdk' => array('pretty_version' => 'v4.1.0', 'version' => '4.1.0.0', 'reference' => '096f3db439f7d77bef2d165dbecd406cc4210550', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-sdk', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-settings' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => 'cb601f00438927dad370ce92c403744c8fa35cf7', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-settings', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-status-report' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => '78bc7cf91e905f1d99ca13478d4af2842796c328', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-status-report', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-third-party-compat' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => 'cd3262cd2bac6f6d5b253abf0edda9051a1cedd5', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-third-party-compat', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-webhooks' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => '3e8c63f9a746abfc79234e7ad85d4e58790b6276', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-webhooks', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-websdk' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => 'fd04181b18ca9ef28d66c267bcbcbe1991105e07', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-websdk', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/payoneer-wp' => array('pretty_version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'version' => 'dev-fix/PN-2320-no-scripts-present-when-plugin-activated-on-a-multisite-site', 'reference' => 'f6967b69c11ee362a2c20e7c240f4fe5f2cf5d0f', 'type' => 'inpsyde-module', 'install_path' => __DIR__ . '/../../modules/inpsyde/payoneer-wp', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/psr-18-wp-http-client' => array('pretty_version' => 'v0.1.0-alpha4', 'version' => '0.1.0.0-alpha4', 'reference' => '8dd172262c95fc3fb4716b14a54c9406254ba441', 'type' => 'library', 'install_path' => __DIR__ . '/../inpsyde/psr-18-wp-http-client', 'aliases' => array(), 'dev_requirement' => \false), 'inpsyde/wp-context' => array('pretty_version' => '1.5.1', 'version' => '1.5.1.0', 'reference' => '1350ada72517f5d374bff9409b4ea5a02377ec1a', 'type' => 'library', 'install_path' => __DIR__ . '/../inpsyde/wp-context', 'aliases' => array(), 'dev_requirement' => \false), 'nyholm/psr7' => array('pretty_version' => '1.8.2', 'version' => '1.8.2.0', 'reference' => 'a71f2b11690f4b24d099d6b16690a90ae14fc6f3', 'type' => 'library', 'install_path' => __DIR__ . '/../nyholm/psr7', 'aliases' => array(), 'dev_requirement' => \false), 'oomphinc/composer-installers-extender' => array('pretty_version' => '2.0.1', 'version' => '2.0.1.0', 'reference' => 'cbf4b6f9a24153b785d09eee755b995ba87bd5f9', 'type' => 'composer-plugin', 'install_path' => __DIR__ . '/../oomphinc/composer-installers-extender', 'aliases' => array(), 'dev_requirement' => \false), 'php-http/message-factory-implementation' => array('dev_requirement' => \false, 'provided' => array(0 => '1.0')), 'psr/container' => array('pretty_version' => '1.1.2', 'version' => '1.1.2.0', 'reference' => '513e0666f7216c7459170d56df27dfcefe1689ea', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/container', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-client' => array('pretty_version' => '1.0.3', 'version' => '1.0.3.0', 'reference' => 'bb5906edc1c324c9a05aa0873d40117941e5fa90', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-client', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-client-implementation' => array('dev_requirement' => \false, 'provided' => array(0 => '^1.0')), 'psr/http-factory' => array('pretty_version' => '1.1.0', 'version' => '1.1.0.0', 'reference' => '2b4765fddfe3b508ac62f829e852b1501d3f6e8a', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-factory', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-factory-implementation' => array('dev_requirement' => \false, 'provided' => array(0 => '1.0')), 'psr/http-message' => array('pretty_version' => '1.1', 'version' => '1.1.0.0', 'reference' => 'cb6ce4845ce34a8ad9e68117c10ee90a29919eba', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-message', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-message-implementation' => array('dev_requirement' => \false, 'provided' => array(0 => '1.0')), 'psr/http-server-handler' => array('pretty_version' => '1.0.2', 'version' => '1.0.2.0', 'reference' => '84c4fb66179be4caaf8e97bd239203245302e7d4', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-server-handler', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-server-middleware' => array('pretty_version' => '1.0.2', 'version' => '1.0.2.0', 'reference' => 'c1481f747daaa6a0782775cd6a8c26a1bf4a3829', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-server-middleware', 'aliases' => array(), 'dev_requirement' => \false), 'psr/log' => array('pretty_version' => '1.1.4', 'version' => '1.1.4.0', 'reference' => 'd49695b909c3b7628b6289db5479a1c204601f11', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/log', 'aliases' => array(), 'dev_requirement' => \false), 'sniccowp/php-scoper-wordpress-excludes' => array('pretty_version' => '6.8.1', 'version' => '6.8.1.0', 'reference' => 'c2c18f89a9aa2d7ef1998d233b9ed00d0deff5dd', 'type' => 'library', 'install_path' => __DIR__ . '/../sniccowp/php-scoper-wordpress-excludes', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/polyfill-php80' => array('pretty_version' => 'v1.32.0', 'version' => '1.32.0.0', 'reference' => '0cc9dd0f17f61d8131e7df6b84bd344899fe2608', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-php80', 'aliases' => array(), 'dev_requirement' => \false), 'wp-oop/containers' => array('pretty_version' => 'v0.1.1-alpha3', 'version' => '0.1.1.0-alpha3', 'reference' => '01f52a9bb347e28aa25e80bd777d6e8b56451d9e', 'type' => 'library', 'install_path' => __DIR__ . '/../wp-oop/containers', 'aliases' => array(), 'dev_requirement' => \false)));
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Container/ContainerConfigurator.php

    r3206335 r3321269  
    66use Syde\Vendor\Psr\Container\ContainerInterface;
    77/**
    8  * @psalm-import-type Service from \Inpsyde\Modularity\Module\ServiceModule
    9  * @psalm-import-type ExtendingService from \Inpsyde\Modularity\Module\ExtendingModule
     8 * @phpstan-import-type Service from \Inpsyde\Modularity\Module\ServiceModule
     9 * @phpstan-import-type ExtendingService from \Inpsyde\Modularity\Module\ExtendingModule
    1010 */
    1111class ContainerConfigurator
     
    101101     * @return ContainerInterface
    102102     *
    103      * @psalm-assert ContainerInterface $this->compiledContainer
     103     * @phpstan-assert ContainerInterface $this->compiledContainer
    104104     */
    105105    public function createReadOnlyContainer(): ContainerInterface
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Container/PackageProxyContainer.php

    r3206335 r3321269  
    3838     * @return bool
    3939     *
    40      * @psalm-assert-if-true ContainerInterface $this->container
    41      * @psalm-assert-if-false null $this->container
     40     * @phpstan-assert-if-true ContainerInterface $this->container
     41     * @phpstan-assert-if-false null $this->container
    4242     */
    4343    private function tryContainer(): bool
     
    5555     * @return void
    5656     *
    57      * @psalm-assert ContainerInterface $this->container
     57     * @phpstan-assert ContainerInterface $this->container
    5858     */
    5959    private function assertPackageBooted(string $id): void
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Container/ReadOnlyContainer.php

    r3206335 r3321269  
    77use Syde\Vendor\Psr\Container\NotFoundExceptionInterface;
    88/**
    9  * @psalm-import-type Service from \Inpsyde\Modularity\Module\ServiceModule
    10  * @psalm-import-type ExtendingService from \Inpsyde\Modularity\Module\ExtendingModule
     9 * @phpstan-import-type Service from \Inpsyde\Modularity\Module\ServiceModule
     10 * @phpstan-import-type ExtendingService from \Inpsyde\Modularity\Module\ExtendingModule
    1111 */
    1212class ReadOnlyContainer implements ContainerInterface
     
    2424     * @param array<string, Service> $services
    2525     * @param array<string, bool> $factoryIds
    26      * @param ServiceExtensions|array $extensions
     26     * @param ServiceExtensions|array<string, ExtendingService> $extensions
    2727     * @param ContainerInterface[] $containers
    2828     */
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Container/ServiceExtensions.php

    r3206335 r3321269  
    66use Syde\Vendor\Psr\Container\ContainerInterface as Container;
    77/**
    8  * @psalm-import-type ExtendingService from \Inpsyde\Modularity\Module\ExtendingModule
     8 * @phpstan-import-type ExtendingService from \Inpsyde\Modularity\Module\ExtendingModule
    99 */
    1010class ServiceExtensions
     
    1717    /**
    1818     * @param string $type
     19     *
    1920     * @return string
    2021     */
     
    2627     * @param string $extensionId
    2728     * @param ExtendingService $extender
     29     *
    2830     * @return static
    2931     */
    3032    public function add(string $extensionId, callable $extender): ServiceExtensions
    3133    {
    32         isset($this->extensions[$extensionId]) or $this->extensions[$extensionId] = [];
     34        if (!isset($this->extensions[$extensionId])) {
     35            $this->extensions[$extensionId] = [];
     36        }
    3337        $this->extensions[$extensionId][] = $extender;
    3438        return $this;
     
    3640    /**
    3741     * @param string $extensionId
     42     *
    3843     * @return bool
    3944     */
     
    4651     * @param string $id
    4752     * @param Container $container
     53     *
    4854     * @return mixed
    4955     */
     
    5763     * @param mixed $service
    5864     * @param Container $container
     65     *
    5966     * @return mixed
    6067     */
     
    7077     * @param object $service
    7178     * @param Container $container
    72      * @param array $extendedClasses
     79     * @param string[] $extendedClasses
     80     *
    7381     * @return mixed
    7482     *
    75      * phpcs:disable Generic.Metrics.CyclomaticComplexity
    76      * phpcs:disable Inpsyde.CodeQuality.ReturnTypeDeclaration
     83     * phpcs:disable SlevomatCodingStandard.Complexity.Cognitive.ComplexityTooHigh
     84     * phpcs:disable Syde.Functions.ReturnTypeDeclaration.NoReturnType
    7785     */
    7886    protected function resolveByType(string $className, object $service, Container $container, array $extendedClasses = [])
    7987    {
    80         // phpcs:enable Generic.Metrics.CyclomaticComplexity
    81         // phpcs:enable Inpsyde.CodeQuality.ReturnTypeDeclaration
     88        // phpcs:enable SlevomatCodingStandard.Complexity.Cognitive.ComplexityTooHigh
     89        // phpcs:enable Syde.Functions.ReturnTypeDeclaration.NoReturnType
    8290        $extendedClasses[] = $className;
    8391        /** @var array<class-string, list<ExtendingService>> $allCallbacks */
     
    8997        }
    9098        // 2nd group of extensions: targeting parent classes
    91         $parents = class_parents($service, \false);
    92         $parents === \false and $parents = [];
     99        $parents = class_parents($service, \false) ?: [];
    93100        foreach ($parents as $parentName) {
    94101            $byParent = $this->extensions[self::typeId($parentName)] ?? null;
     
    98105        }
    99106        // 3rd group of extensions: targeting implemented interfaces
    100         $interfaces = class_implements($service, \false);
    101         $interfaces === \false and $interfaces = [];
     107        $interfaces = class_implements($service, \false) ?: [];
    102108        foreach ($interfaces as $interfaceName) {
    103109            $byInterface = $this->extensions[self::typeId($interfaceName)] ?? null;
     
    137143     * @param Container $container
    138144     * @param list<ExtendingService> $extenders
     145     *
    139146     * @return list{mixed, int}
    140147     */
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Module/ExtendingModule.php

    r3206335 r3321269  
    66use Syde\Vendor\Psr\Container\ContainerInterface;
    77/**
    8  * @psalm-type ExtendingService = callable(mixed $service, ContainerInterface $container):mixed
     8 * @phpstan-type ExtendingService callable(mixed $service, ContainerInterface $container): mixed
    99 */
    1010interface ExtendingModule extends Module
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Module/FactoryModule.php

    r3206335 r3321269  
    55
    66/**
    7  * @psalm-import-type Service from ServiceModule
     7 * @phpstan-import-type Service from ServiceModule
    88 */
    99interface FactoryModule extends Module
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Module/ServiceModule.php

    r3206335 r3321269  
    66use Syde\Vendor\Psr\Container\ContainerInterface;
    77/**
    8  * @psalm-type Service = callable(ContainerInterface $container):mixed
     8 * @phpstan-type Service callable(ContainerInterface $container): mixed
    99 */
    1010interface ServiceModule extends Module
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Package.php

    r3206335 r3321269  
    66use Syde\Vendor\Inpsyde\Modularity\Container\ContainerConfigurator;
    77use Syde\Vendor\Inpsyde\Modularity\Container\PackageProxyContainer;
     8use Syde\Vendor\Inpsyde\Modularity\Module\ExecutableModule;
    89use Syde\Vendor\Inpsyde\Modularity\Module\ExtendingModule;
    9 use Syde\Vendor\Inpsyde\Modularity\Module\ExecutableModule;
    1010use Syde\Vendor\Inpsyde\Modularity\Module\FactoryModule;
    1111use Syde\Vendor\Inpsyde\Modularity\Module\Module;
     
    1414use Syde\Vendor\Psr\Container\ContainerInterface;
    1515/**
    16  * @psalm-import-type Service from \Inpsyde\Modularity\Module\ServiceModule
    17  * @psalm-import-type ExtendingService from \Inpsyde\Modularity\Module\ExtendingModule
     16 * @phpstan-import-type Service from \Inpsyde\Modularity\Module\ServiceModule
     17 * @phpstan-import-type ExtendingService from \Inpsyde\Modularity\Module\ExtendingModule
    1818 */
    1919class Package
     
    168168    public static function new(Properties $properties, ContainerInterface ...$containers): Package
    169169    {
    170         return new self($properties, ...array_values($containers));
     170        return new self($properties, ...$containers);
    171171    }
    172172    /**
    173173     * @param Properties $properties
    174      * @param list<ContainerInterface> $containers
     174     * @param ContainerInterface ...$containers
    175175     */
    176176    private function __construct(Properties $properties, ContainerInterface ...$containers)
     
    213213     * @param Package $package
    214214     * @return bool
    215      *
    216      * phpcs:disable Inpsyde.CodeQuality.FunctionLength
    217215     */
    218216    public function connect(Package $package): bool
    219217    {
    220         // phpcs:enable Inpsyde.CodeQuality.FunctionLength
    221218        try {
    222219            if ($package === $this) {
     
    399396        /** @var null|array<string, Service|ExtendingService> $services */
    400397        $services = null;
    401         /** @var null|callable(string, Service|ExtendingService) $addCallback */
     398        /** @var null|callable(string, Service|ExtendingService): void $addCallback */
    402399        $addCallback = null;
    403400        switch ($status) {
     
    444441    private function moduleProgress(string $moduleId, string $status, ?array $serviceIds = null): void
    445442    {
    446         isset($this->moduleStatus[$status]) or $this->moduleStatus[$status] = [];
     443        if (!isset($this->moduleStatus[$status])) {
     444            $this->moduleStatus[$status] = [];
     445        }
    447446        $this->moduleStatus[$status][] = $moduleId;
    448447        if ($serviceIds === null || $serviceIds === [] || !$this->properties->isDebug()) {
     
    591590     * @param string $reason
    592591     * @param bool $throw
    593      * @return ($throw is true ? never: false)
     592     * @return bool
    594593     */
    595594    private function handleConnectionFailure(string $packageName, string $reason, bool $throw): bool
     
    643642        if (apply_filters('deprecated_argument_trigger_error', \true)) {
    644643            do_action('wp_trigger_error_run', $function, $message, \E_USER_DEPRECATED);
     644            // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_trigger_error
    645645            trigger_error(esc_html($message), \E_USER_DEPRECATED);
    646646        }
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Properties/BaseProperties.php

    r3206335 r3321269  
    1818     * @param array<string, mixed> $properties
    1919     */
    20     protected function __construct(string $baseName, string $basePath, string $baseUrl = null, array $properties = [])
     20    protected function __construct(string $baseName, string $basePath, ?string $baseUrl = null, array $properties = [])
    2121    {
    2222        $baseName = $this->sanitizeBaseName($baseName);
     
    3232    /**
    3333     * @param string $name
     34     *
    3435     * @return lowercase-string
    3536     */
    3637    protected function sanitizeBaseName(string $name): string
    3738    {
    38         substr_count($name, '/') and $name = dirname($name);
     39        if (substr_count($name, '/')) {
     40            $name = dirname($name);
     41        }
    3942        return strtolower(pathinfo($name, \PATHINFO_FILENAME));
    4043    }
     
    133136    }
    134137    /**
    135      * @return array
     138     * @return string[]
    136139     */
    137140    public function tags(): array
     
    142145     * @param string $key
    143146     * @param mixed $default
     147     *
    144148     * @return mixed
    145149     */
     
    150154    /**
    151155     * @param string $key
     156     *
    152157     * @return bool
    153158     */
     
    163168    {
    164169        if ($this->isDebug === null) {
    165             /** @psalm-suppress TypeDoesNotContainType */
    166170            $this->isDebug = defined('WP_DEBUG') && \WP_DEBUG;
    167171        }
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Properties/LibraryProperties.php

    r3206335 r3321269  
    44namespace Syde\Vendor\Inpsyde\Modularity\Properties;
    55
     6/**
     7 * @phpstan-type ComposerAuthor array{
     8 *      name: string,
     9 *      email?: string,
     10 *      homepage?: string,
     11 *      role?: string,
     12 * }
     13 * @phpstan-type ComposerData array{
     14 *      name: string,
     15 *      version?: string,
     16 *      require?: array<string, string>,
     17 *      require-dev?: array<string, string>,
     18 *      description?: string,
     19 *      keywords?: string[],
     20 *      authors?: ComposerAuthor[],
     21 *      extra?: array{modularity?: array<string, string>},
     22 * }
     23 */
    624class LibraryProperties extends BaseProperties
    725{
     
    1129     * @param string $composerJsonFile
    1230     * @param string|null $baseUrl
     31     *
    1332     * @return LibraryProperties
    1433     *
    15      * phpcs:disable Generic.Metrics.CyclomaticComplexity
     34     * phpcs:disable SlevomatCodingStandard.Complexity
    1635     */
    1736    public static function new(string $composerJsonFile, ?string $baseUrl = null): LibraryProperties
    1837    {
    19         // phpcs:enable Generic.Metrics.CyclomaticComplexity
    20         if (!\is_file($composerJsonFile) || !\is_readable($composerJsonFile)) {
    21             throw new \Exception(esc_html("File {$composerJsonFile} does not exist or is not readable."));
    22         }
    23         $content = (string) file_get_contents($composerJsonFile);
    24         /** @var array $composerJsonData */
    25         $composerJsonData = json_decode($content, \true);
     38        // phpcs:enable SlevomatCodingStandard.Complexity
     39        $composerJsonData = self::readComposerJsonData($composerJsonFile);
    2640        $properties = Properties::DEFAULT_PROPERTIES;
    2741        $properties[self::PROP_DESCRIPTION] = $composerJsonData['description'] ?? '';
    2842        $properties[self::PROP_TAGS] = $composerJsonData['keywords'] ?? [];
    2943        $authors = $composerJsonData['authors'] ?? [];
    30         is_array($authors) or $authors = [];
     44        if (!is_array($authors)) {
     45            $authors = [];
     46        }
    3147        $names = [];
    3248        foreach ($authors as $author) {
     
    4864        // Custom settings which can be stored in composer.json "extra.modularity"
    4965        $extra = $composerJsonData['extra']['modularity'] ?? [];
    50         is_array($extra) or $extra = [];
     66        if (!is_array($extra)) {
     67            $extra = [];
     68        }
    5169        foreach (self::EXTRA_KEYS as $key) {
    5270            $properties[$key] = $extra[$key] ?? '';
     
    6886    /**
    6987     * @param string $url
     88     *
    7089     * @return static
    7190     */
     
    7998    }
    8099    /**
    81      * @param array $composerJsonData
    82      * @return list{string, string}
     100     * @param ComposerData $composerJsonData
     101     *
     102     * @return array{string, string}
    83103     */
    84     private static function buildNames(array $composerJsonData): array
     104    protected static function buildNames(array $composerJsonData): array
    85105    {
    86106        $composerName = (string) ($composerJsonData['name'] ?? '');
    87107        $packageNamePieces = explode('/', $composerName, 2);
    88108        $basename = implode('-', $packageNamePieces);
    89         // From "inpsyde/foo-bar-baz" to  "Inpsyde Foo Bar Baz"
     109        // From "syde/foo-bar-baz" to  "Syde Foo Bar Baz"
    90110        $name = mb_convert_case(str_replace(['-', '_', '.'], ' ', implode(' ', $packageNamePieces)), \MB_CASE_TITLE);
    91111        return [$basename, $name];
     
    101121     * `>= 7.1 < 8`    returns `7.1`
    102122     *
    103      * @param array $composerData
     123     * @param ComposerData $composerData
    104124     * @param string $key
     125     *
    105126     * @return string
    106      *
    107      * phpcs:disable Generic.Metrics.CyclomaticComplexity
    108127     */
    109     private static function extractPhpVersion(array $composerData, string $key = 'require'): string
     128    protected static function extractPhpVersion(array $composerData, string $key = 'require'): string
    110129    {
    111         // phpcs:enable Generic.Metrics.CyclomaticComplexity
    112130        $nextKey = $key === 'require' ? 'require-dev' : null;
    113131        $base = $composerData[$key] ?? null;
     
    134152    /**
    135153     * @param string $version
     154     *
    136155     * @return string
    137156     */
    138     private static function parseVersion(string $version): string
     157    protected static function parseVersion(string $version): string
    139158    {
    140159        $version = trim($version);
     
    156175        return '';
    157176    }
     177    /**
     178     * @param string $composerJsonFile
     179     *
     180     * @return ComposerData
     181     * @throws \Exception
     182     */
     183    private static function readComposerJsonData(string $composerJsonFile): array
     184    {
     185        if (!\is_file($composerJsonFile) || !\is_readable($composerJsonFile)) {
     186            throw new \Exception(esc_html("File {$composerJsonFile} does not exist or is not readable."));
     187        }
     188        $content = (string) file_get_contents($composerJsonFile);
     189        /** @var ComposerData $composerJsonData */
     190        $composerJsonData = json_decode($content, \true);
     191        if (json_last_error() !== \JSON_ERROR_NONE) {
     192            throw new \Exception(esc_html("Error reading file {$composerJsonFile}: " . json_last_error_msg()));
     193        }
     194        return $composerJsonData;
     195    }
    158196}
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Properties/PluginProperties.php

    r3206335 r3321269  
    8282    }
    8383    /**
    84      * @return array
     84     * @return string[]
    8585     */
    8686    public function requiresPlugins(): array
  • payoneer-checkout/trunk/vendor/inpsyde/modularity/src/Properties/Properties.php

    r3206335 r3321269  
    9090     * Optional. Specify the minimum required PHP version.
    9191     *
    92      * @return string
     92     * @return string|null
    9393     */
    9494    public function requiresPhp(): ?string;
     
    9797     * Plugins do not have support for "tags"/"keywords" in header.
    9898     *
    99      * @return array
     99     * @return string[]
    100100     *
    101101     * @see https://developer.wordpress.org/reference/classes/wp_theme/#properties
  • payoneer-checkout/trunk/vendor/scoper-autoload.php

    r3305047 r3321269  
    3030    }
    3131}
     32humbug_phpscoper_expose_class('Stringable', 'Syde\Vendor\Stringable');
     33humbug_phpscoper_expose_class('Attribute', 'Syde\Vendor\Attribute');
     34humbug_phpscoper_expose_class('ValueError', 'Syde\Vendor\ValueError');
     35humbug_phpscoper_expose_class('PhpToken', 'Syde\Vendor\PhpToken');
    3236humbug_phpscoper_expose_class('UnhandledMatchError', 'Syde\Vendor\UnhandledMatchError');
    33 humbug_phpscoper_expose_class('Attribute', 'Syde\Vendor\Attribute');
    34 humbug_phpscoper_expose_class('Stringable', 'Syde\Vendor\Stringable');
    35 humbug_phpscoper_expose_class('PhpToken', 'Syde\Vendor\PhpToken');
    36 humbug_phpscoper_expose_class('ValueError', 'Syde\Vendor\ValueError');
    3737
    3838// Function aliases. For more information see:
  • payoneer-checkout/trunk/vendor/sniccowp/php-scoper-wordpress-excludes/generated/exclude-wordpress-classes.json

    r3260742 r3321269  
    377377    "WP_oEmbed_Controller",
    378378    "WP_Paused_Extensions_Storage",
     379    "WP_PHPMailer",
    379380    "WP_Plugins_List_Table",
    380381    "WP_Plugin_Dependencies",
     
    473474    "WP_Site_Icon",
    474475    "WP_Site_Query",
     476    "WP_Speculation_Rules",
    475477    "WP_Styles",
    476478    "WP_Style_Engine",
     
    502504    "WP_Upgrader",
    503505    "WP_Upgrader_Skin",
     506    "WP_URL_Pattern_Prefixer",
    504507    "WP_User",
    505508    "WP_Users_List_Table",
  • payoneer-checkout/trunk/vendor/sniccowp/php-scoper-wordpress-excludes/generated/exclude-wordpress-functions.json

    r3260742 r3321269  
    8484    "apply_block_core_search_border_styles",
    8585    "apply_block_hooks_to_content",
     86    "apply_block_hooks_to_content_from_post_object",
    8687    "apply_filters",
    8788    "apply_filters_deprecated",
     
    139140    "block_core_navigation_get_most_recently_published_navigation",
    140141    "block_core_navigation_get_post_ids",
    141     "block_core_navigation_insert_hooked_blocks",
    142     "block_core_navigation_insert_hooked_blocks_into_rest_response",
    143142    "block_core_navigation_link_build_css_colors",
    144143    "block_core_navigation_link_build_css_font_sizes",
     
    148147    "block_core_navigation_link_render_submenu_icon",
    149148    "block_core_navigation_maybe_use_classic_menu_fallback",
    150     "block_core_navigation_mock_parsed_block",
    151149    "block_core_navigation_parse_blocks_from_menu_items",
    152     "block_core_navigation_remove_serialized_parent_block",
    153150    "block_core_navigation_render_submenu_icon",
    154     "block_core_navigation_set_ignored_hooked_blocks_metadata",
    155151    "block_core_navigation_sort_menu_items_by_parent_id",
    156152    "block_core_navigation_submenu_build_css_colors",
     
    158154    "block_core_navigation_submenu_render_submenu_icon",
    159155    "block_core_navigation_typographic_presets_backcompatibility",
    160     "block_core_navigation_update_ignore_hooked_blocks_meta",
    161156    "block_core_page_list_build_css_colors",
    162157    "block_core_page_list_build_css_font_sizes",
     
    11871182    "is_plugin_page",
    11881183    "is_plugin_paused",
     1184    "is_post_embeddable",
    11891185    "is_post_publicly_viewable",
    11901186    "is_post_status_viewable",
     
    15411537    "register_block_core_query_pagination_previous",
    15421538    "register_block_core_query_title",
     1539    "register_block_core_query_total",
    15431540    "register_block_core_read_more",
    15441541    "register_block_core_rss",
     
    16751672    "render_block_core_query_pagination_previous",
    16761673    "render_block_core_query_title",
     1674    "render_block_core_query_total",
    16771675    "render_block_core_read_more",
    16781676    "render_block_core_rss",
     
    23612359    "wp_allow_comment",
    23622360    "wp_apply_alignment_support",
     2361    "wp_apply_aria_label_support",
    23632362    "wp_apply_border_support",
    23642363    "wp_apply_colors_support",
     
    26182617    "wp_enqueue_stored_styles",
    26192618    "wp_enqueue_style",
     2619    "wp_ensure_editable_role",
    26202620    "wp_exif_date2ts",
    26212621    "wp_exif_frac2dec",
     
    26242624    "wp_ext2type",
    26252625    "wp_extract_urls",
     2626    "wp_fast_hash",
    26262627    "wp_favicon_request",
    26272628    "wp_filesize",
     
    27882789    "wp_get_sitemap_providers",
    27892790    "wp_get_sites",
     2791    "wp_get_speculation_rules",
     2792    "wp_get_speculation_rules_configuration",
    27902793    "wp_get_split_term",
    27912794    "wp_get_split_terms",
     
    28542857    "wp_increase_content_media_count",
    28552858    "wp_initialize_site",
     2859    "wp_initialize_site_preview_hooks",
    28562860    "wp_initialize_theme_preview_hooks",
    28572861    "wp_initial_constants",
     
    30873091    "wp_parse_widget_id",
    30883092    "wp_password_change_notification",
     3093    "wp_password_needs_rehash",
    30893094    "wp_paused_plugins",
    30903095    "wp_paused_themes",
     
    31323137    "wp_print_scripts",
    31333138    "wp_print_script_tag",
     3139    "wp_print_speculation_rules",
    31343140    "wp_print_styles",
    31353141    "wp_print_theme_file_tree",
     
    31693175    "wp_register",
    31703176    "wp_register_alignment_support",
     3177    "wp_register_aria_label_support",
    31713178    "wp_register_background_support",
    31723179    "wp_register_block_metadata_collection",
    31733180    "wp_register_block_style_variations_from_theme_json_partials",
     3181    "wp_register_block_types_from_metadata_collection",
    31743182    "wp_register_border_support",
    31753183    "wp_register_colors_support",
     
    32303238    "wp_render_elements_support",
    32313239    "wp_render_elements_support_styles",
     3240    "wp_render_empty_block_template_warning",
    32323241    "wp_render_layout_support_flag",
    32333242    "wp_render_position_support",
     
    33263335    "wp_shortlink_wp_head",
    33273336    "wp_should_add_elements_class_name",
     3337    "wp_should_load_block_assets_on_demand",
    33283338    "wp_should_load_block_editor_scripts_and_styles",
    33293339    "wp_should_load_separate_core_block_assets",
     
    34183428    "wp_unique_filename",
    34193429    "wp_unique_id",
     3430    "wp_unique_id_from_values",
    34203431    "wp_unique_post_slug",
    34213432    "wp_unique_prefixed_id",
     
    34793490    "wp_validate_site_data",
    34803491    "wp_validate_user_request_key",
     3492    "wp_verify_fast_hash",
    34813493    "wp_verify_nonce",
    34823494    "wp_version_check",
     
    37773789    "_wp_get_post_revision_version",
    37783790    "_wp_get_presets_class_name",
     3791    "_wp_get_site_editor_redirection_url",
    37793792    "_wp_get_user_contactmethods",
    37803793    "_wp_handle_upload",
  • payoneer-checkout/trunk/vendor/symfony/polyfill-php80/PhpToken.php

    r3114998 r3321269  
    2727    public $text;
    2828    /**
    29      * @var int
     29     * @var -1|positive-int
    3030     */
    3131    public $line;
     
    3434     */
    3535    public $pos;
     36    /**
     37     * @param -1|positive-int $line
     38     */
    3639    public function __construct(int $id, string $text, int $line = -1, int $position = -1)
    3740    {
     
    6972    }
    7073    /**
    71      * @return static[]
     74     * @return list<static>
    7275     */
    7376    public static function tokenize(string $code, int $flags = 0): array
Note: See TracChangeset for help on using the changeset viewer.