diff --git a/BitPayLib/class-bitpaycancelorder.php b/BitPayLib/class-bitpaycancelorder.php index 5b862da3..988aec5b 100644 --- a/BitPayLib/class-bitpaycancelorder.php +++ b/BitPayLib/class-bitpaycancelorder.php @@ -8,7 +8,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/BitPayLib/class-bitpaycart.php b/BitPayLib/class-bitpaycart.php index b45b5e04..f3d5b09c 100644 --- a/BitPayLib/class-bitpaycart.php +++ b/BitPayLib/class-bitpaycart.php @@ -8,7 +8,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/BitPayLib/class-bitpaycheckouttransactions.php b/BitPayLib/class-bitpaycheckouttransactions.php index 428a29e6..843717ae 100644 --- a/BitPayLib/class-bitpaycheckouttransactions.php +++ b/BitPayLib/class-bitpaycheckouttransactions.php @@ -11,7 +11,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/BitPayLib/class-bitpayclientfactory.php b/BitPayLib/class-bitpayclientfactory.php index 2eab5829..d8c6802c 100644 --- a/BitPayLib/class-bitpayclientfactory.php +++ b/BitPayLib/class-bitpayclientfactory.php @@ -13,7 +13,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/BitPayLib/class-bitpayinvoicecreate.php b/BitPayLib/class-bitpayinvoicecreate.php index 902a82c1..f7c1a14f 100644 --- a/BitPayLib/class-bitpayinvoicecreate.php +++ b/BitPayLib/class-bitpayinvoicecreate.php @@ -13,7 +13,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ @@ -89,6 +89,7 @@ public function execute(): void { wp_redirect( $bitpay_invoice->getRedirectURL() ); // phpcs:ignore exit(); } catch ( BitPayException $e ) { + $this->bitpay_logger->execute( $e->getMessage(), 'NEW BITPAY INVOICE', false, true ); $error_url = get_home_url() . '/' . $bitpay_checkout_options['bitpay_checkout_error']; $order = new \WC_Order( $order_id ); $items = $order->get_items(); @@ -106,6 +107,7 @@ public function execute(): void { wp_redirect( $error_url ); // phpcs:ignore die(); } catch ( \Exception $e ) { + $this->bitpay_logger->execute( $e->getMessage(), 'NEW BITPAY INVOICE', false, true ); global $woocommerce; $cart_url = $woocommerce->cart->get_cart_url(); wp_redirect( $cart_url ); // phpcs:ignore diff --git a/BitPayLib/class-bitpayipnprocess.php b/BitPayLib/class-bitpayipnprocess.php index 3da53bb3..c904112d 100644 --- a/BitPayLib/class-bitpayipnprocess.php +++ b/BitPayLib/class-bitpayipnprocess.php @@ -13,7 +13,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/BitPayLib/class-bitpaylogger.php b/BitPayLib/class-bitpaylogger.php index 3f539d8c..4d22272b 100644 --- a/BitPayLib/class-bitpaylogger.php +++ b/BitPayLib/class-bitpaylogger.php @@ -8,7 +8,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/BitPayLib/class-bitpaypages.php b/BitPayLib/class-bitpaypages.php index 70b90986..fc4749fa 100644 --- a/BitPayLib/class-bitpaypages.php +++ b/BitPayLib/class-bitpaypages.php @@ -7,7 +7,7 @@ /** * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/BitPayLib/class-bitpaypaymentsettings.php b/BitPayLib/class-bitpaypaymentsettings.php index 92807524..7ed3c827 100644 --- a/BitPayLib/class-bitpaypaymentsettings.php +++ b/BitPayLib/class-bitpaypaymentsettings.php @@ -8,7 +8,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ @@ -137,14 +137,6 @@ public function get_checkout_message(): string { return $this->get_bitpay_gateway_setting( 'bitpay_checkout_checkout_message', '' ); } - private function get_bitpay_gateway_setting( string $setting_name, $default_value = null ): ?string { - return $this->get_bitpay_gateway_settings()[ $setting_name ] ?? $default_value; - } - - private function get_bitpay_gateway_settings(): array { - return get_option( 'woocommerce_bitpay_checkout_gateway_settings', array() ); - } - public function get_close_url(): ?string { return $this->get_bitpay_gateway_setting( 'bitpay_close_url', null ); } @@ -170,4 +162,18 @@ public function get_checkout_slug(): ?string { return $slug; } + + public function get_payment_logo_url(): string { + $logo = $this->get_bitpay_gateway_setting( 'bitpay_logo', 'BitPay-Accepted-CardGroup' ); + + return plugins_url( '../../images/', __FILE__ ) . $logo . '.svg'; + } + + private function get_bitpay_gateway_setting( string $setting_name, $default_value = null ): ?string { + return $this->get_bitpay_gateway_settings()[ $setting_name ] ?? $default_value; + } + + private function get_bitpay_gateway_settings(): array { + return get_option( 'woocommerce_bitpay_checkout_gateway_settings', array() ); + } } diff --git a/BitPayLib/class-bitpaypluginsetup.php b/BitPayLib/class-bitpaypluginsetup.php index af74acc3..16c25e3c 100644 --- a/BitPayLib/class-bitpaypluginsetup.php +++ b/BitPayLib/class-bitpaypluginsetup.php @@ -10,7 +10,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/BitPayLib/class-wcgatewaybitpay.php b/BitPayLib/class-wcgatewaybitpay.php index 873bd0d9..d3c83abc 100644 --- a/BitPayLib/class-wcgatewaybitpay.php +++ b/BitPayLib/class-wcgatewaybitpay.php @@ -8,7 +8,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ @@ -28,7 +28,6 @@ public function __construct() { if ( empty( $_GET['woo-bitpay-return'] ) ) { // phpcs:ignore $this->order_button_text = __( 'Pay with BitPay', 'woocommerce-gateway-bitpay_checkout_gateway' ); - } $this->init_form_fields(); @@ -40,6 +39,7 @@ public function __construct() { add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) ); add_action( 'woocommerce_email_before_order_table', array( $this, 'email_instructions' ), 10, 3 ); + wp_enqueue_script( 'bitpay_wc_gateway', plugins_url( '../../js/wc_gateway_bitpay.js', __FILE__ ), null, 1, false ); } public function email_instructions( $order, $sent_to_admin, $plain_text = false ) { if ( $this->instructions && ! $sent_to_admin && 'bitpay_checkout_gateway' === $order->get_payment_method() && $order->has_status( 'processing' ) ) { @@ -47,6 +47,7 @@ public function email_instructions( $order, $sent_to_admin, $plain_text = false } } public function init_form_fields() { + $settings = new BitPayPaymentSettings(); $wc_statuses_arr = wc_get_order_statuses(); unset( $wc_statuses_arr['wc-cancelled'] ); unset( $wc_statuses_arr['wc-refunded'] ); @@ -62,6 +63,32 @@ public function init_form_fields() { 'description' => '', 'default' => 'no', ), + 'bitpay_logo' => array( + 'title' => __( 'BitPay Logo', 'woocommerce' ), + 'type' => 'select', + 'description' => '', + 'options' => array( + 'BitPay-Accepted-CardGroup' => 'BitPay Accepted', + 'BitPay-Accepted-CardGroup-DarkMode' => 'BitPay Accepted (Dark mode)', + 'Pay-with-BitPay-CardGroup' => 'Pay with BitPay', + 'Pay-with-BitPay-CardGroup-DarkMode' => 'Pay with BitPay (Dark mode)', + 'BitPay-Accepted-Card-Alt' => 'BitPay Accepted Card - Alt', + 'BitPay-Accepted-Card-Alt-DarkMode' => 'BitPay Accepted Card - Alt (Dark mode)', + 'BitPay-Accepted-Card' => 'BitPay Accepted Card', + 'BitPay-Accepted-Card-DarkMode' => 'BitPay Accepted Card (Dark mode)', + 'BitPay-Accepted-Card-GrayScale' => 'BitPay Accepted Card - Grayscale', + 'PayWith-BitPay-Card2x' => 'Pay with BitPay Card', + 'PayWith-BitPay-Card-Alt' => 'Pay with BitPay Card - Alt', + 'PayWith-BitPay-Card-GrayScale' => 'Pay with BitPay Card - Grayscale', + 'PayWith-BitPay-Card-DarkMode' => 'Pay with BitPay Card (Dark mode)', + ), + 'default' => 'BitPay-Accepted-CardGroup', + ), + 'bitpay_logo_image' => array( + 'id' => 'bitpay_logo', + 'description' => '', + 'type' => 'title', + ), 'bitpay_checkout_info' => array( 'description' => __( 'You should not ship any products until BitPay has finalized your transaction.
The order will stay in a Hold and/or Processing state, and will automatically change to Completed after the payment has been confirmed.', 'woocommerce' ), 'type' => 'title', @@ -244,8 +271,9 @@ public function process_payment( $order_id ) { } private function get_icon_on_payment_page(): string { - $brand = '//bitpay.com/cdn/merchant-resources/pay-with-bitpay-card-group.svg'; - return $brand . '" class="bitpay_logo"'; + $settings = new BitPayPaymentSettings(); + + return $settings->get_payment_logo_url() . '" id="bitpay_logo"'; } private function get_processing_link(): string { diff --git a/BitPayLib/trait-wpdbhelper.php b/BitPayLib/trait-wpdbhelper.php index 81322f6f..8d68cc97 100644 --- a/BitPayLib/trait-wpdbhelper.php +++ b/BitPayLib/trait-wpdbhelper.php @@ -10,7 +10,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/CHANGELOG.md b/CHANGELOG.md index 604f35f6..3c82644b 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,8 +2,13 @@ All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +# 5.1.0 +* Add admin option to allow users to select their BitPay button +* log create invoice issues + # 5.0.1 * Fix support for PHP 8.0 + # 5.0.0 * Improve code quality * Use BitPay SDK diff --git a/images/BitPay-Accepted-Card-Alt-DarkMode.svg b/images/BitPay-Accepted-Card-Alt-DarkMode.svg new file mode 100644 index 00000000..ecec9f00 --- /dev/null +++ b/images/BitPay-Accepted-Card-Alt-DarkMode.svg @@ -0,0 +1,171 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/images/BitPay-Accepted-Card-Alt.svg b/images/BitPay-Accepted-Card-Alt.svg new file mode 100644 index 00000000..6fb77b95 --- /dev/null +++ b/images/BitPay-Accepted-Card-Alt.svg @@ -0,0 +1,172 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/images/BitPay-Accepted-Card-DarkMode.svg b/images/BitPay-Accepted-Card-DarkMode.svg new file mode 100644 index 00000000..90c1c26b --- /dev/null +++ b/images/BitPay-Accepted-Card-DarkMode.svg @@ -0,0 +1,30 @@ + + + + BitPay-Accepted-Card-DarkMode + Created with Sketch. + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/images/BitPay-Accepted-Card-GrayScale.svg b/images/BitPay-Accepted-Card-GrayScale.svg new file mode 100644 index 00000000..08a6bc80 --- /dev/null +++ b/images/BitPay-Accepted-Card-GrayScale.svg @@ -0,0 +1,34 @@ + + + + BitPay-Accepted-Card-GrayScale + Created with Sketch. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/images/BitPay-Accepted-Card.svg b/images/BitPay-Accepted-Card.svg new file mode 100644 index 00000000..1423c717 --- /dev/null +++ b/images/BitPay-Accepted-Card.svg @@ -0,0 +1,30 @@ + + + + BitPay-Accepted-Card + Created with Sketch. + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/images/BitPay-Accepted-CardGroup-DarkMode.svg b/images/BitPay-Accepted-CardGroup-DarkMode.svg new file mode 100644 index 00000000..3d6f70a5 --- /dev/null +++ b/images/BitPay-Accepted-CardGroup-DarkMode.svg @@ -0,0 +1,172 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/images/BitPay-Accepted-CardGroup.svg b/images/BitPay-Accepted-CardGroup.svg new file mode 100644 index 00000000..96e6a000 --- /dev/null +++ b/images/BitPay-Accepted-CardGroup.svg @@ -0,0 +1,177 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/images/Pay-with-BitPay-CardGroup-DarkMode.svg b/images/Pay-with-BitPay-CardGroup-DarkMode.svg new file mode 100644 index 00000000..5663d134 --- /dev/null +++ b/images/Pay-with-BitPay-CardGroup-DarkMode.svg @@ -0,0 +1,173 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/images/Pay-with-BitPay-CardGroup.svg b/images/Pay-with-BitPay-CardGroup.svg new file mode 100644 index 00000000..43132242 --- /dev/null +++ b/images/Pay-with-BitPay-CardGroup.svg @@ -0,0 +1,178 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/images/PayWith-BitPay-Card-Alt.svg b/images/PayWith-BitPay-Card-Alt.svg new file mode 100644 index 00000000..3073bdf8 --- /dev/null +++ b/images/PayWith-BitPay-Card-Alt.svg @@ -0,0 +1,37 @@ + + + + PayWith-BitPay-Card-Alt + Created with Sketch. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/images/PayWith-BitPay-Card-DarkMode.svg b/images/PayWith-BitPay-Card-DarkMode.svg new file mode 100644 index 00000000..78a25f0c --- /dev/null +++ b/images/PayWith-BitPay-Card-DarkMode.svg @@ -0,0 +1,35 @@ + + + + PayWith-BitPay-Card-DarkMode + Created with Sketch. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/images/PayWith-BitPay-Card-GrayScale.svg b/images/PayWith-BitPay-Card-GrayScale.svg new file mode 100644 index 00000000..238fb9db --- /dev/null +++ b/images/PayWith-BitPay-Card-GrayScale.svg @@ -0,0 +1,37 @@ + + + + PayWith-BitPay-Card-GrayScale + Created with Sketch. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/images/PayWith-BitPay-Card2x.svg b/images/PayWith-BitPay-Card2x.svg new file mode 100644 index 00000000..166214ae --- /dev/null +++ b/images/PayWith-BitPay-Card2x.svg @@ -0,0 +1,35 @@ + + + + PayWith-BitPay-Card + Created with Sketch. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/index.php b/index.php index 002a7200..93cfe9d0 100644 --- a/index.php +++ b/index.php @@ -3,7 +3,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.1 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/js/wc_gateway_bitpay.js b/js/wc_gateway_bitpay.js new file mode 100644 index 00000000..3add3526 --- /dev/null +++ b/js/wc_gateway_bitpay.js @@ -0,0 +1,19 @@ +jQuery( document ).ready( + function () { + const logo = jQuery( "#woocommerce_bitpay_checkout_gateway_bitpay_logo" ); + if ( logo.length === 0 ) { + return; + } + + logo.on( + "change", + function () { + const image = jQuery( "#woocommerce_bitpay_checkout_gateway_bitpay_logo_image" ).next(); + const url = window.location.origin + '/wp-content/plugins/bitpay-checkout-for-woocommerce/images/' + + this.value + '.svg' + + image.html( '' ); + } + ) + } +); diff --git a/readme.txt b/readme.txt index df06aa17..4b9a073f 100644 --- a/readme.txt +++ b/readme.txt @@ -111,6 +111,10 @@ You can contact our support team via the following form https://bitpay.com/reque == Changelog == += 5.1.0 = +* Add admin option to allow users to select their BitPay button +* log create invoice issues + = 5.0.1 = * Fix support for PHP 8.0 diff --git a/vendorPrefixed/BitPayLib/class-bitpaycancelorder.php b/vendorPrefixed/BitPayLib/class-bitpaycancelorder.php index 265fec3b..f8e0d884 100644 --- a/vendorPrefixed/BitPayLib/class-bitpaycancelorder.php +++ b/vendorPrefixed/BitPayLib/class-bitpaycancelorder.php @@ -7,7 +7,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/vendorPrefixed/BitPayLib/class-bitpaycart.php b/vendorPrefixed/BitPayLib/class-bitpaycart.php index 87fea89d..3ecdc63a 100644 --- a/vendorPrefixed/BitPayLib/class-bitpaycart.php +++ b/vendorPrefixed/BitPayLib/class-bitpaycart.php @@ -7,7 +7,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/vendorPrefixed/BitPayLib/class-bitpaycheckouttransactions.php b/vendorPrefixed/BitPayLib/class-bitpaycheckouttransactions.php index 82affa01..d1bd8f4e 100644 --- a/vendorPrefixed/BitPayLib/class-bitpaycheckouttransactions.php +++ b/vendorPrefixed/BitPayLib/class-bitpaycheckouttransactions.php @@ -9,7 +9,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/vendorPrefixed/BitPayLib/class-bitpayclientfactory.php b/vendorPrefixed/BitPayLib/class-bitpayclientfactory.php index f48d0de2..2136cb7e 100644 --- a/vendorPrefixed/BitPayLib/class-bitpayclientfactory.php +++ b/vendorPrefixed/BitPayLib/class-bitpayclientfactory.php @@ -11,7 +11,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/vendorPrefixed/BitPayLib/class-bitpayinvoicecreate.php b/vendorPrefixed/BitPayLib/class-bitpayinvoicecreate.php index 18b07957..3b95c6ed 100644 --- a/vendorPrefixed/BitPayLib/class-bitpayinvoicecreate.php +++ b/vendorPrefixed/BitPayLib/class-bitpayinvoicecreate.php @@ -11,7 +11,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ @@ -71,6 +71,7 @@ public function execute() : void // phpcs:ignore exit; } catch (BitPayException $e) { + $this->bitpay_logger->execute($e->getMessage(), 'NEW BITPAY INVOICE', \false, \true); $error_url = get_home_url() . '/' . $bitpay_checkout_options['bitpay_checkout_error']; $order = new \WC_Order($order_id); $items = $order->get_items(); @@ -89,6 +90,7 @@ public function execute() : void // phpcs:ignore die; } catch (\Exception $e) { + $this->bitpay_logger->execute($e->getMessage(), 'NEW BITPAY INVOICE', \false, \true); global $woocommerce; $cart_url = $woocommerce->cart->get_cart_url(); wp_redirect($cart_url); diff --git a/vendorPrefixed/BitPayLib/class-bitpayipnprocess.php b/vendorPrefixed/BitPayLib/class-bitpayipnprocess.php index c1c62d83..b20330df 100644 --- a/vendorPrefixed/BitPayLib/class-bitpayipnprocess.php +++ b/vendorPrefixed/BitPayLib/class-bitpayipnprocess.php @@ -11,7 +11,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/vendorPrefixed/BitPayLib/class-bitpaylogger.php b/vendorPrefixed/BitPayLib/class-bitpaylogger.php index 3808c141..87752b21 100644 --- a/vendorPrefixed/BitPayLib/class-bitpaylogger.php +++ b/vendorPrefixed/BitPayLib/class-bitpaylogger.php @@ -7,7 +7,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/vendorPrefixed/BitPayLib/class-bitpaypages.php b/vendorPrefixed/BitPayLib/class-bitpaypages.php index 6ae20e8e..59f957cc 100644 --- a/vendorPrefixed/BitPayLib/class-bitpaypages.php +++ b/vendorPrefixed/BitPayLib/class-bitpaypages.php @@ -6,7 +6,7 @@ /** * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/vendorPrefixed/BitPayLib/class-bitpaypaymentsettings.php b/vendorPrefixed/BitPayLib/class-bitpaypaymentsettings.php index 64a74004..21e1fc3a 100644 --- a/vendorPrefixed/BitPayLib/class-bitpaypaymentsettings.php +++ b/vendorPrefixed/BitPayLib/class-bitpaypaymentsettings.php @@ -7,7 +7,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ @@ -130,14 +130,6 @@ public function get_checkout_message() : string { return $this->get_bitpay_gateway_setting('bitpay_checkout_checkout_message', ''); } - private function get_bitpay_gateway_setting(string $setting_name, $default_value = null) : ?string - { - return $this->get_bitpay_gateway_settings()[$setting_name] ?? $default_value; - } - private function get_bitpay_gateway_settings() : array - { - return get_option('woocommerce_bitpay_checkout_gateway_settings', array()); - } public function get_close_url() : ?string { return $this->get_bitpay_gateway_setting('bitpay_close_url', null); @@ -162,4 +154,17 @@ public function get_checkout_slug() : ?string } return $slug; } + public function get_payment_logo_url() : string + { + $logo = $this->get_bitpay_gateway_setting('bitpay_logo', 'BitPay-Accepted-CardGroup'); + return plugins_url('../../images/', __FILE__) . $logo . '.svg'; + } + private function get_bitpay_gateway_setting(string $setting_name, $default_value = null) : ?string + { + return $this->get_bitpay_gateway_settings()[$setting_name] ?? $default_value; + } + private function get_bitpay_gateway_settings() : array + { + return get_option('woocommerce_bitpay_checkout_gateway_settings', array()); + } } diff --git a/vendorPrefixed/BitPayLib/class-bitpaypluginsetup.php b/vendorPrefixed/BitPayLib/class-bitpaypluginsetup.php index 55ca4c13..48194ab0 100644 --- a/vendorPrefixed/BitPayLib/class-bitpaypluginsetup.php +++ b/vendorPrefixed/BitPayLib/class-bitpaypluginsetup.php @@ -8,7 +8,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/vendorPrefixed/BitPayLib/class-wcgatewaybitpay.php b/vendorPrefixed/BitPayLib/class-wcgatewaybitpay.php index 69565eaf..22688da4 100644 --- a/vendorPrefixed/BitPayLib/class-wcgatewaybitpay.php +++ b/vendorPrefixed/BitPayLib/class-wcgatewaybitpay.php @@ -7,7 +7,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ @@ -35,6 +35,7 @@ public function __construct() $this->instructions = $this->get_option('instructions', $this->description); add_action('woocommerce_update_options_payment_gateways_' . $this->id, array($this, 'process_admin_options')); add_action('woocommerce_email_before_order_table', array($this, 'email_instructions'), 10, 3); + wp_enqueue_script('bitpay_wc_gateway', plugins_url('../../js/wc_gateway_bitpay.js', __FILE__), null, 1, \false); } public function email_instructions($order, $sent_to_admin, $plain_text = \false) { @@ -44,13 +45,14 @@ public function email_instructions($order, $sent_to_admin, $plain_text = \false) } public function init_form_fields() { + $settings = new BitPayPaymentSettings(); $wc_statuses_arr = wc_get_order_statuses(); unset($wc_statuses_arr['wc-cancelled']); unset($wc_statuses_arr['wc-refunded']); unset($wc_statuses_arr['wc-failed']); $wc_statuses_arr[self::IGNORE_STATUS_VALUE] = 'Do not change status'; // add an ignore option. - $this->form_fields = array('enabled' => array('title' => __('Enable/Disable', 'woocommerce'), 'label' => __('Enable BitPay', 'woocommerce'), 'type' => 'checkbox', 'description' => '', 'default' => 'no'), 'bitpay_checkout_info' => array('description' => __('You should not ship any products until BitPay has finalized your transaction.
The order will stay in a Hold and/or Processing state, and will automatically change to Completed after the payment has been confirmed.', 'woocommerce'), 'type' => 'title'), 'bitpay_checkout_merchant_info' => array('description' => __('If you have not created a BitPay Merchant Token, you can create one on your BitPay Dashboard.
(Test) or (Production)

', 'woocommerce'), 'type' => 'title'), 'bitpay_checkout_tier_info' => array('description' => __('*** If you are having trouble creating BitPay invoices, verify your Tier settings on your BitPay Dashboard.', 'woocommerce'), 'type' => 'title'), 'description' => array('title' => __('Description', 'woocommerce'), 'type' => 'text', 'description' => __('This is the message box that will appear on the checkout page when they select BitPay.', 'woocommerce'), 'default' => 'Pay with BitPay using one of the supported cryptocurrencies'), 'bitpay_checkout_token_dev' => array('title' => __('Development Token', 'woocommerce'), 'label' => __('Development Token', 'woocommerce'), 'type' => 'text', 'description' => 'Your development merchant token. Create one here and uncheck `Require Authentication`.', 'default' => ''), 'bitpay_checkout_token_prod' => array('title' => __('Production Token', 'woocommerce'), 'label' => __('Production Token', 'woocommerce'), 'type' => 'text', 'description' => 'Your production merchant token. Create one here and uncheck `Require Authentication`.', 'default' => ''), 'bitpay_checkout_endpoint' => array('title' => __('Endpoint', 'woocommerce'), 'type' => 'select', 'description' => __('Select Test for testing the plugin, Production when you are ready to go live.'), 'options' => array('production' => 'Production', 'test' => 'Test'), 'default' => 'test'), 'bitpay_checkout_flow' => array( + $this->form_fields = array('enabled' => array('title' => __('Enable/Disable', 'woocommerce'), 'label' => __('Enable BitPay', 'woocommerce'), 'type' => 'checkbox', 'description' => '', 'default' => 'no'), 'bitpay_logo' => array('title' => __('BitPay Logo', 'woocommerce'), 'type' => 'select', 'description' => '', 'options' => array('BitPay-Accepted-CardGroup' => 'BitPay Accepted', 'BitPay-Accepted-CardGroup-DarkMode' => 'BitPay Accepted (Dark mode)', 'Pay-with-BitPay-CardGroup' => 'Pay with BitPay', 'Pay-with-BitPay-CardGroup-DarkMode' => 'Pay with BitPay (Dark mode)', 'BitPay-Accepted-Card-Alt' => 'BitPay Accepted Card - Alt', 'BitPay-Accepted-Card-Alt-DarkMode' => 'BitPay Accepted Card - Alt (Dark mode)', 'BitPay-Accepted-Card' => 'BitPay Accepted Card', 'BitPay-Accepted-Card-DarkMode' => 'BitPay Accepted Card (Dark mode)', 'BitPay-Accepted-Card-GrayScale' => 'BitPay Accepted Card - Grayscale', 'PayWith-BitPay-Card2x' => 'Pay with BitPay Card', 'PayWith-BitPay-Card-Alt' => 'Pay with BitPay Card - Alt', 'PayWith-BitPay-Card-GrayScale' => 'Pay with BitPay Card - Grayscale', 'PayWith-BitPay-Card-DarkMode' => 'Pay with BitPay Card (Dark mode)'), 'default' => 'BitPay-Accepted-CardGroup'), 'bitpay_logo_image' => array('id' => 'bitpay_logo', 'description' => '', 'type' => 'title'), 'bitpay_checkout_info' => array('description' => __('You should not ship any products until BitPay has finalized your transaction.
The order will stay in a Hold and/or Processing state, and will automatically change to Completed after the payment has been confirmed.', 'woocommerce'), 'type' => 'title'), 'bitpay_checkout_merchant_info' => array('description' => __('If you have not created a BitPay Merchant Token, you can create one on your BitPay Dashboard.
(Test) or (Production)

', 'woocommerce'), 'type' => 'title'), 'bitpay_checkout_tier_info' => array('description' => __('*** If you are having trouble creating BitPay invoices, verify your Tier settings on your BitPay Dashboard.', 'woocommerce'), 'type' => 'title'), 'description' => array('title' => __('Description', 'woocommerce'), 'type' => 'text', 'description' => __('This is the message box that will appear on the checkout page when they select BitPay.', 'woocommerce'), 'default' => 'Pay with BitPay using one of the supported cryptocurrencies'), 'bitpay_checkout_token_dev' => array('title' => __('Development Token', 'woocommerce'), 'label' => __('Development Token', 'woocommerce'), 'type' => 'text', 'description' => 'Your development merchant token. Create one here and uncheck `Require Authentication`.', 'default' => ''), 'bitpay_checkout_token_prod' => array('title' => __('Production Token', 'woocommerce'), 'label' => __('Production Token', 'woocommerce'), 'type' => 'text', 'description' => 'Your production merchant token. Create one here and uncheck `Require Authentication`.', 'default' => ''), 'bitpay_checkout_endpoint' => array('title' => __('Endpoint', 'woocommerce'), 'type' => 'select', 'description' => __('Select Test for testing the plugin, Production when you are ready to go live.'), 'options' => array('production' => 'Production', 'test' => 'Test'), 'default' => 'test'), 'bitpay_checkout_flow' => array( 'title' => __('Checkout Flow', 'woocommerce'), 'type' => 'select', 'description' => __('If this is set to Redirect, then the customer will be redirected to BitPay to checkout, and return to the checkout page once the payment is made.
If this is set to Modal, the user will stay on ' . get_bloginfo('name', null) . ' and complete the transaction.', 'woocommerce'), @@ -73,8 +75,8 @@ public function process_payment($order_id) } private function get_icon_on_payment_page() : string { - $brand = '//bitpay.com/cdn/merchant-resources/pay-with-bitpay-card-group.svg'; - return $brand . '" class="bitpay_logo"'; + $settings = new BitPayPaymentSettings(); + return $settings->get_payment_logo_url() . '" id="bitpay_logo"'; } private function get_processing_link() : string { diff --git a/vendorPrefixed/BitPayLib/trait-wpdbhelper.php b/vendorPrefixed/BitPayLib/trait-wpdbhelper.php index 96b358e3..ffa4921c 100644 --- a/vendorPrefixed/BitPayLib/trait-wpdbhelper.php +++ b/vendorPrefixed/BitPayLib/trait-wpdbhelper.php @@ -8,7 +8,7 @@ * Plugin Name: BitPay Checkout for WooCommerce * Plugin URI: https://www.bitpay.com * Description: BitPay Checkout Plugin - * Version: 5.0.0 + * Version: 5.1.0 * Author: BitPay * Author URI: mailto:integrations@bitpay.com?subject=BitPay Checkout for WooCommerce */ diff --git a/vendorPrefixed/vendor/autoload.php b/vendorPrefixed/vendor/autoload.php index 8198d539..0b2682ff 100644 --- a/vendorPrefixed/vendor/autoload.php +++ b/vendorPrefixed/vendor/autoload.php @@ -22,4 +22,4 @@ require_once __DIR__ . '/composer/autoload_real.php'; -return ComposerAutoloaderInitcf583310376124902e9ac538bdad4c87::getLoader(); +return ComposerAutoloaderInite162ea33b4500611893693c28524b1e9::getLoader(); diff --git a/vendorPrefixed/vendor/composer/autoload_real.php b/vendorPrefixed/vendor/composer/autoload_real.php index cfb64176..17718ef4 100644 --- a/vendorPrefixed/vendor/composer/autoload_real.php +++ b/vendorPrefixed/vendor/composer/autoload_real.php @@ -2,7 +2,7 @@ // autoload_real.php @generated by Composer -class ComposerAutoloaderInitcf583310376124902e9ac538bdad4c87 +class ComposerAutoloaderInite162ea33b4500611893693c28524b1e9 { private static $loader; @@ -24,16 +24,16 @@ public static function getLoader() require __DIR__ . '/platform_check.php'; - spl_autoload_register(array('ComposerAutoloaderInitcf583310376124902e9ac538bdad4c87', 'loadClassLoader'), true, true); + spl_autoload_register(array('ComposerAutoloaderInite162ea33b4500611893693c28524b1e9', 'loadClassLoader'), true, true); self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); - spl_autoload_unregister(array('ComposerAutoloaderInitcf583310376124902e9ac538bdad4c87', 'loadClassLoader')); + spl_autoload_unregister(array('ComposerAutoloaderInite162ea33b4500611893693c28524b1e9', 'loadClassLoader')); require __DIR__ . '/autoload_static.php'; - call_user_func(\Composer\Autoload\ComposerStaticInitcf583310376124902e9ac538bdad4c87::getInitializer($loader)); + call_user_func(\Composer\Autoload\ComposerStaticInite162ea33b4500611893693c28524b1e9::getInitializer($loader)); $loader->register(true); - $filesToLoad = \Composer\Autoload\ComposerStaticInitcf583310376124902e9ac538bdad4c87::$files; + $filesToLoad = \Composer\Autoload\ComposerStaticInite162ea33b4500611893693c28524b1e9::$files; $requireFile = \Closure::bind(static function ($fileIdentifier, $file) { if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true; diff --git a/vendorPrefixed/vendor/composer/autoload_static.php b/vendorPrefixed/vendor/composer/autoload_static.php index e08439a0..8d9be097 100644 --- a/vendorPrefixed/vendor/composer/autoload_static.php +++ b/vendorPrefixed/vendor/composer/autoload_static.php @@ -4,7 +4,7 @@ namespace Composer\Autoload; -class ComposerStaticInitcf583310376124902e9ac538bdad4c87 +class ComposerStaticInite162ea33b4500611893693c28524b1e9 { public static $files = array ( '320cde22f66dd4f5d3fd621d3e88b98f' => __DIR__ . '/..' . '/symfony/polyfill-ctype/bootstrap.php', @@ -385,9 +385,9 @@ class ComposerStaticInitcf583310376124902e9ac538bdad4c87 public static function getInitializer(ClassLoader $loader) { return \Closure::bind(function () use ($loader) { - $loader->prefixLengthsPsr4 = ComposerStaticInitcf583310376124902e9ac538bdad4c87::$prefixLengthsPsr4; - $loader->prefixDirsPsr4 = ComposerStaticInitcf583310376124902e9ac538bdad4c87::$prefixDirsPsr4; - $loader->classMap = ComposerStaticInitcf583310376124902e9ac538bdad4c87::$classMap; + $loader->prefixLengthsPsr4 = ComposerStaticInite162ea33b4500611893693c28524b1e9::$prefixLengthsPsr4; + $loader->prefixDirsPsr4 = ComposerStaticInite162ea33b4500611893693c28524b1e9::$prefixDirsPsr4; + $loader->classMap = ComposerStaticInite162ea33b4500611893693c28524b1e9::$classMap; }, null, ClassLoader::class); } diff --git a/vendorPrefixed/vendor/composer/installed.php b/vendorPrefixed/vendor/composer/installed.php index 85e8d44d..c3c81a73 100644 --- a/vendorPrefixed/vendor/composer/installed.php +++ b/vendorPrefixed/vendor/composer/installed.php @@ -2,4 +2,4 @@ namespace BitPayVendor; -return array('root' => array('name' => 'bitpay/bitpay-checkout-for-woocommerce', 'pretty_version' => 'dev-master', 'version' => 'dev-master', 'reference' => '440db2e76ce1a295059295653bc225f540aa7b13', 'type' => 'library', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), 'dev' => \true), 'versions' => array('bitpay/bitpay-checkout-for-woocommerce' => array('pretty_version' => 'dev-master', 'version' => 'dev-master', 'reference' => '440db2e76ce1a295059295653bc225f540aa7b13', 'type' => 'library', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), 'dev_requirement' => \false), 'bitpay/key-utils' => array('pretty_version' => '1.1.2', 'version' => '1.1.2.0', 'reference' => '44283014751d1886b41c7de29f1972737d6dfe4d', 'type' => 'library', 'install_path' => __DIR__ . '/../bitpay/key-utils', 'aliases' => array(), 'dev_requirement' => \false), 'bitpay/sdk' => array('pretty_version' => '8.0.0', 'version' => '8.0.0.0', 'reference' => '73c9184fec5f7518953e24b7c6e9f0d5f771c815', 'type' => 'library', 'install_path' => __DIR__ . '/../bitpay/sdk', 'aliases' => array(), 'dev_requirement' => \false), 'dealerdirect/phpcodesniffer-composer-installer' => array('pretty_version' => 'v1.0.0', 'version' => '1.0.0.0', 'reference' => '4be43904336affa5c2f70744a348312336afd0da', 'type' => 'composer-plugin', 'install_path' => __DIR__ . '/../dealerdirect/phpcodesniffer-composer-installer', 'aliases' => array(), 'dev_requirement' => \true), 'fidry/console' => array('pretty_version' => '0.5.5', 'version' => '0.5.5.0', 'reference' => 'bc1fe03f600c63f12ec0a39c6b746c1a1fb77bf7', 'type' => 'library', 'install_path' => __DIR__ . '/../fidry/console', 'aliases' => array(), 'dev_requirement' => \false), 'guzzlehttp/guzzle' => array('pretty_version' => '7.7.0', 'version' => '7.7.0.0', 'reference' => 'fb7566caccf22d74d1ab270de3551f72a58399f5', 'type' => 'library', 'install_path' => __DIR__ . '/../guzzlehttp/guzzle', 'aliases' => array(), 'dev_requirement' => \false), 'guzzlehttp/promises' => array('pretty_version' => '2.0.0', 'version' => '2.0.0.0', 'reference' => '3a494dc7dc1d7d12e511890177ae2d0e6c107da6', 'type' => 'library', 'install_path' => __DIR__ . '/../guzzlehttp/promises', 'aliases' => array(), 'dev_requirement' => \false), 'guzzlehttp/psr7' => array('pretty_version' => '2.5.0', 'version' => '2.5.0.0', 'reference' => 'b635f279edd83fc275f822a1188157ffea568ff6', 'type' => 'library', 'install_path' => __DIR__ . '/../guzzlehttp/psr7', 'aliases' => array(), 'dev_requirement' => \false), 'humbug/php-scoper' => array('pretty_version' => '0.18.3', 'version' => '0.18.3.0', 'reference' => '1a49b88b7961152daf534757137b8f86f67fde23', 'type' => 'library', 'install_path' => __DIR__ . '/../humbug/php-scoper', 'aliases' => array(), 'dev_requirement' => \false), 'jetbrains/phpstorm-stubs' => array('pretty_version' => 'v2022.3', 'version' => '2022.3.0.0', 'reference' => '6b568c153cea002dc6fad96285c3063d07cab18d', 'type' => 'library', 'install_path' => __DIR__ . '/../jetbrains/phpstorm-stubs', 'aliases' => array(), 'dev_requirement' => \false), 'netresearch/jsonmapper' => array('pretty_version' => 'v4.2.0', 'version' => '4.2.0.0', 'reference' => 'f60565f8c0566a31acf06884cdaa591867ecc956', 'type' => 'library', 'install_path' => __DIR__ . '/../netresearch/jsonmapper', 'aliases' => array(), 'dev_requirement' => \false), 'nikic/php-parser' => array('pretty_version' => 'v4.17.1', 'version' => '4.17.1.0', 'reference' => 'a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d', 'type' => 'library', 'install_path' => __DIR__ . '/../nikic/php-parser', 'aliases' => array(), 'dev_requirement' => \false), 'phpcsstandards/phpcsextra' => array('pretty_version' => '1.1.0', 'version' => '1.1.0.0', 'reference' => '61a9be9f74a53735f7c421d7de8dc64fa80488e6', 'type' => 'phpcodesniffer-standard', 'install_path' => __DIR__ . '/../phpcsstandards/phpcsextra', 'aliases' => array(), 'dev_requirement' => \true), 'phpcsstandards/phpcsutils' => array('pretty_version' => '1.0.8', 'version' => '1.0.8.0', 'reference' => '69465cab9d12454e5e7767b9041af0cd8cd13be7', 'type' => 'phpcodesniffer-standard', 'install_path' => __DIR__ . '/../phpcsstandards/phpcsutils', 'aliases' => array(), 'dev_requirement' => \true), 'psr/container' => array('pretty_version' => '2.0.2', 'version' => '2.0.2.0', 'reference' => 'c71ecc56dfe541dbd90c5360474fbc405f8d5963', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/container', 'aliases' => array(), 'dev_requirement' => \false), 'psr/event-dispatcher' => array('pretty_version' => '1.0.0', 'version' => '1.0.0.0', 'reference' => 'dbefd12671e8a14ec7f180cab83036ed26714bb0', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/event-dispatcher', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-client' => array('pretty_version' => '1.0.2', 'version' => '1.0.2.0', 'reference' => '0955afe48220520692d2d09f7ab7e0f93ffd6a31', '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.0.2', 'version' => '1.0.2.0', 'reference' => 'e616d01114759c4c489f93b099585439f795fe35', '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' => '2.0', 'version' => '2.0.0.0', 'reference' => '402d35bcb92c70c026d1a6a9883f06b2ead23d71', '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/log-implementation' => array('dev_requirement' => \false, 'provided' => array(0 => '1.0|2.0|3.0')), 'ralouphie/getallheaders' => array('pretty_version' => '3.0.3', 'version' => '3.0.3.0', 'reference' => '120b605dfeb996808c31b6477290a714d356e822', 'type' => 'library', 'install_path' => __DIR__ . '/../ralouphie/getallheaders', 'aliases' => array(), 'dev_requirement' => \false), 'squizlabs/php_codesniffer' => array('pretty_version' => '3.7.2', 'version' => '3.7.2.0', 'reference' => 'ed8e00df0a83aa96acf703f8c2979ff33341f879', 'type' => 'library', 'install_path' => __DIR__ . '/../squizlabs/php_codesniffer', 'aliases' => array(), 'dev_requirement' => \true), 'symfony/console' => array('pretty_version' => 'v6.3.2', 'version' => '6.3.2.0', 'reference' => 'aa5d64ad3f63f2e48964fc81ee45cb318a723898', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/console', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/deprecation-contracts' => array('pretty_version' => 'v3.0.2', 'version' => '3.0.2.0', 'reference' => '26954b3d62a6c5fd0ea8a2a00c0353a14978d05c', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/deprecation-contracts', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/event-dispatcher-contracts' => array('pretty_version' => 'v3.3.0', 'version' => '3.3.0.0', 'reference' => 'a76aed96a42d2b521153fb382d418e30d18b59df', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/event-dispatcher-contracts', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/filesystem' => array('pretty_version' => 'v6.3.1', 'version' => '6.3.1.0', 'reference' => 'edd36776956f2a6fcf577edb5b05eb0e3bdc52ae', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/filesystem', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/finder' => array('pretty_version' => 'v6.3.3', 'version' => '6.3.3.0', 'reference' => '9915db259f67d21eefee768c1abcf1cc61b1fc9e', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/finder', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/polyfill-ctype' => array('pretty_version' => 'v1.27.0', 'version' => '1.27.0.0', 'reference' => '5bbc823adecdae860bb64756d639ecfec17b050a', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-ctype', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/polyfill-intl-grapheme' => array('pretty_version' => 'v1.27.0', 'version' => '1.27.0.0', 'reference' => '511a08c03c1960e08a883f4cffcacd219b758354', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-intl-grapheme', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/polyfill-intl-normalizer' => array('pretty_version' => 'v1.27.0', 'version' => '1.27.0.0', 'reference' => '19bd1e4fcd5b91116f14d8533c57831ed00571b6', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-intl-normalizer', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/polyfill-mbstring' => array('pretty_version' => 'v1.27.0', 'version' => '1.27.0.0', 'reference' => '8ad114f6b39e2c98a8b0e3bd907732c207c2b534', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-mbstring', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/service-contracts' => array('pretty_version' => 'v3.3.0', 'version' => '3.3.0.0', 'reference' => '40da9cc13ec349d9e4966ce18b5fbcd724ab10a4', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/service-contracts', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/string' => array('pretty_version' => 'v6.3.2', 'version' => '6.3.2.0', 'reference' => '53d1a83225002635bca3482fcbf963001313fb68', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/string', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/yaml' => array('pretty_version' => 'v6.0.19', 'version' => '6.0.19.0', 'reference' => 'deec3a812a0305a50db8ae689b183f43d915c884', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/yaml', 'aliases' => array(), 'dev_requirement' => \false), 'thecodingmachine/safe' => array('pretty_version' => 'v2.5.0', 'version' => '2.5.0.0', 'reference' => '3115ecd6b4391662b4931daac4eba6b07a2ac1f0', 'type' => 'library', 'install_path' => __DIR__ . '/../thecodingmachine/safe', 'aliases' => array(), 'dev_requirement' => \false), 'webmozart/assert' => array('pretty_version' => '1.11.0', 'version' => '1.11.0.0', 'reference' => '11cb2199493b2f8a3b53e7f19068fc6aac760991', 'type' => 'library', 'install_path' => __DIR__ . '/../webmozart/assert', 'aliases' => array(), 'dev_requirement' => \false), 'wp-coding-standards/wpcs' => array('pretty_version' => 'dev-develop', 'version' => 'dev-develop', 'reference' => '1767f3a1169407d84f1d17e4cd9d80844d693e9e', 'type' => 'phpcodesniffer-standard', 'install_path' => __DIR__ . '/../wp-coding-standards/wpcs', 'aliases' => array(0 => '9999999-dev'), 'dev_requirement' => \true))); +return array('root' => array('name' => 'bitpay/bitpay-checkout-for-woocommerce', 'pretty_version' => 'dev-master', 'version' => 'dev-master', 'reference' => '19a362c6ecd24426f974cf62f2dec8ce820160da', 'type' => 'library', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), 'dev' => \true), 'versions' => array('bitpay/bitpay-checkout-for-woocommerce' => array('pretty_version' => 'dev-master', 'version' => 'dev-master', 'reference' => '19a362c6ecd24426f974cf62f2dec8ce820160da', 'type' => 'library', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), 'dev_requirement' => \false), 'bitpay/key-utils' => array('pretty_version' => '1.1.2', 'version' => '1.1.2.0', 'reference' => '44283014751d1886b41c7de29f1972737d6dfe4d', 'type' => 'library', 'install_path' => __DIR__ . '/../bitpay/key-utils', 'aliases' => array(), 'dev_requirement' => \false), 'bitpay/sdk' => array('pretty_version' => '8.0.0', 'version' => '8.0.0.0', 'reference' => '73c9184fec5f7518953e24b7c6e9f0d5f771c815', 'type' => 'library', 'install_path' => __DIR__ . '/../bitpay/sdk', 'aliases' => array(), 'dev_requirement' => \false), 'dealerdirect/phpcodesniffer-composer-installer' => array('pretty_version' => 'v1.0.0', 'version' => '1.0.0.0', 'reference' => '4be43904336affa5c2f70744a348312336afd0da', 'type' => 'composer-plugin', 'install_path' => __DIR__ . '/../dealerdirect/phpcodesniffer-composer-installer', 'aliases' => array(), 'dev_requirement' => \true), 'fidry/console' => array('pretty_version' => '0.5.5', 'version' => '0.5.5.0', 'reference' => 'bc1fe03f600c63f12ec0a39c6b746c1a1fb77bf7', 'type' => 'library', 'install_path' => __DIR__ . '/../fidry/console', 'aliases' => array(), 'dev_requirement' => \false), 'guzzlehttp/guzzle' => array('pretty_version' => '7.7.0', 'version' => '7.7.0.0', 'reference' => 'fb7566caccf22d74d1ab270de3551f72a58399f5', 'type' => 'library', 'install_path' => __DIR__ . '/../guzzlehttp/guzzle', 'aliases' => array(), 'dev_requirement' => \false), 'guzzlehttp/promises' => array('pretty_version' => '2.0.0', 'version' => '2.0.0.0', 'reference' => '3a494dc7dc1d7d12e511890177ae2d0e6c107da6', 'type' => 'library', 'install_path' => __DIR__ . '/../guzzlehttp/promises', 'aliases' => array(), 'dev_requirement' => \false), 'guzzlehttp/psr7' => array('pretty_version' => '2.5.0', 'version' => '2.5.0.0', 'reference' => 'b635f279edd83fc275f822a1188157ffea568ff6', 'type' => 'library', 'install_path' => __DIR__ . '/../guzzlehttp/psr7', 'aliases' => array(), 'dev_requirement' => \false), 'humbug/php-scoper' => array('pretty_version' => '0.18.3', 'version' => '0.18.3.0', 'reference' => '1a49b88b7961152daf534757137b8f86f67fde23', 'type' => 'library', 'install_path' => __DIR__ . '/../humbug/php-scoper', 'aliases' => array(), 'dev_requirement' => \false), 'jetbrains/phpstorm-stubs' => array('pretty_version' => 'v2022.3', 'version' => '2022.3.0.0', 'reference' => '6b568c153cea002dc6fad96285c3063d07cab18d', 'type' => 'library', 'install_path' => __DIR__ . '/../jetbrains/phpstorm-stubs', 'aliases' => array(), 'dev_requirement' => \false), 'netresearch/jsonmapper' => array('pretty_version' => 'v4.2.0', 'version' => '4.2.0.0', 'reference' => 'f60565f8c0566a31acf06884cdaa591867ecc956', 'type' => 'library', 'install_path' => __DIR__ . '/../netresearch/jsonmapper', 'aliases' => array(), 'dev_requirement' => \false), 'nikic/php-parser' => array('pretty_version' => 'v4.17.1', 'version' => '4.17.1.0', 'reference' => 'a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d', 'type' => 'library', 'install_path' => __DIR__ . '/../nikic/php-parser', 'aliases' => array(), 'dev_requirement' => \false), 'phpcsstandards/phpcsextra' => array('pretty_version' => '1.1.0', 'version' => '1.1.0.0', 'reference' => '61a9be9f74a53735f7c421d7de8dc64fa80488e6', 'type' => 'phpcodesniffer-standard', 'install_path' => __DIR__ . '/../phpcsstandards/phpcsextra', 'aliases' => array(), 'dev_requirement' => \true), 'phpcsstandards/phpcsutils' => array('pretty_version' => '1.0.8', 'version' => '1.0.8.0', 'reference' => '69465cab9d12454e5e7767b9041af0cd8cd13be7', 'type' => 'phpcodesniffer-standard', 'install_path' => __DIR__ . '/../phpcsstandards/phpcsutils', 'aliases' => array(), 'dev_requirement' => \true), 'psr/container' => array('pretty_version' => '2.0.2', 'version' => '2.0.2.0', 'reference' => 'c71ecc56dfe541dbd90c5360474fbc405f8d5963', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/container', 'aliases' => array(), 'dev_requirement' => \false), 'psr/event-dispatcher' => array('pretty_version' => '1.0.0', 'version' => '1.0.0.0', 'reference' => 'dbefd12671e8a14ec7f180cab83036ed26714bb0', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/event-dispatcher', 'aliases' => array(), 'dev_requirement' => \false), 'psr/http-client' => array('pretty_version' => '1.0.2', 'version' => '1.0.2.0', 'reference' => '0955afe48220520692d2d09f7ab7e0f93ffd6a31', '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.0.2', 'version' => '1.0.2.0', 'reference' => 'e616d01114759c4c489f93b099585439f795fe35', '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' => '2.0', 'version' => '2.0.0.0', 'reference' => '402d35bcb92c70c026d1a6a9883f06b2ead23d71', '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/log-implementation' => array('dev_requirement' => \false, 'provided' => array(0 => '1.0|2.0|3.0')), 'ralouphie/getallheaders' => array('pretty_version' => '3.0.3', 'version' => '3.0.3.0', 'reference' => '120b605dfeb996808c31b6477290a714d356e822', 'type' => 'library', 'install_path' => __DIR__ . '/../ralouphie/getallheaders', 'aliases' => array(), 'dev_requirement' => \false), 'squizlabs/php_codesniffer' => array('pretty_version' => '3.7.2', 'version' => '3.7.2.0', 'reference' => 'ed8e00df0a83aa96acf703f8c2979ff33341f879', 'type' => 'library', 'install_path' => __DIR__ . '/../squizlabs/php_codesniffer', 'aliases' => array(), 'dev_requirement' => \true), 'symfony/console' => array('pretty_version' => 'v6.3.2', 'version' => '6.3.2.0', 'reference' => 'aa5d64ad3f63f2e48964fc81ee45cb318a723898', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/console', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/deprecation-contracts' => array('pretty_version' => 'v3.0.2', 'version' => '3.0.2.0', 'reference' => '26954b3d62a6c5fd0ea8a2a00c0353a14978d05c', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/deprecation-contracts', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/event-dispatcher-contracts' => array('pretty_version' => 'v3.3.0', 'version' => '3.3.0.0', 'reference' => 'a76aed96a42d2b521153fb382d418e30d18b59df', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/event-dispatcher-contracts', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/filesystem' => array('pretty_version' => 'v6.3.1', 'version' => '6.3.1.0', 'reference' => 'edd36776956f2a6fcf577edb5b05eb0e3bdc52ae', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/filesystem', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/finder' => array('pretty_version' => 'v6.3.3', 'version' => '6.3.3.0', 'reference' => '9915db259f67d21eefee768c1abcf1cc61b1fc9e', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/finder', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/polyfill-ctype' => array('pretty_version' => 'v1.27.0', 'version' => '1.27.0.0', 'reference' => '5bbc823adecdae860bb64756d639ecfec17b050a', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-ctype', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/polyfill-intl-grapheme' => array('pretty_version' => 'v1.27.0', 'version' => '1.27.0.0', 'reference' => '511a08c03c1960e08a883f4cffcacd219b758354', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-intl-grapheme', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/polyfill-intl-normalizer' => array('pretty_version' => 'v1.27.0', 'version' => '1.27.0.0', 'reference' => '19bd1e4fcd5b91116f14d8533c57831ed00571b6', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-intl-normalizer', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/polyfill-mbstring' => array('pretty_version' => 'v1.27.0', 'version' => '1.27.0.0', 'reference' => '8ad114f6b39e2c98a8b0e3bd907732c207c2b534', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-mbstring', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/service-contracts' => array('pretty_version' => 'v3.3.0', 'version' => '3.3.0.0', 'reference' => '40da9cc13ec349d9e4966ce18b5fbcd724ab10a4', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/service-contracts', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/string' => array('pretty_version' => 'v6.3.2', 'version' => '6.3.2.0', 'reference' => '53d1a83225002635bca3482fcbf963001313fb68', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/string', 'aliases' => array(), 'dev_requirement' => \false), 'symfony/yaml' => array('pretty_version' => 'v6.0.19', 'version' => '6.0.19.0', 'reference' => 'deec3a812a0305a50db8ae689b183f43d915c884', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/yaml', 'aliases' => array(), 'dev_requirement' => \false), 'thecodingmachine/safe' => array('pretty_version' => 'v2.5.0', 'version' => '2.5.0.0', 'reference' => '3115ecd6b4391662b4931daac4eba6b07a2ac1f0', 'type' => 'library', 'install_path' => __DIR__ . '/../thecodingmachine/safe', 'aliases' => array(), 'dev_requirement' => \false), 'webmozart/assert' => array('pretty_version' => '1.11.0', 'version' => '1.11.0.0', 'reference' => '11cb2199493b2f8a3b53e7f19068fc6aac760991', 'type' => 'library', 'install_path' => __DIR__ . '/../webmozart/assert', 'aliases' => array(), 'dev_requirement' => \false), 'wp-coding-standards/wpcs' => array('pretty_version' => 'dev-develop', 'version' => 'dev-develop', 'reference' => '1767f3a1169407d84f1d17e4cd9d80844d693e9e', 'type' => 'phpcodesniffer-standard', 'install_path' => __DIR__ . '/../wp-coding-standards/wpcs', 'aliases' => array(0 => '9999999-dev'), 'dev_requirement' => \true))); diff --git a/vendorPrefixed/vendor/scoper-autoload.php b/vendorPrefixed/vendor/scoper-autoload.php index 42bca643..d5feb2ee 100644 --- a/vendorPrefixed/vendor/scoper-autoload.php +++ b/vendorPrefixed/vendor/scoper-autoload.php @@ -30,7 +30,7 @@ function humbug_phpscoper_expose_class(string $exposed, string $prefixed): void } humbug_phpscoper_expose_class('JsonMapper', 'BitPayVendor\JsonMapper'); humbug_phpscoper_expose_class('JsonMapper_Exception', 'BitPayVendor\JsonMapper_Exception'); -humbug_phpscoper_expose_class('ComposerAutoloaderInitcf583310376124902e9ac538bdad4c87', 'BitPayVendor\ComposerAutoloaderInitcf583310376124902e9ac538bdad4c87'); +humbug_phpscoper_expose_class('ComposerAutoloaderInite162ea33b4500611893693c28524b1e9', 'BitPayVendor\ComposerAutoloaderInite162ea33b4500611893693c28524b1e9'); humbug_phpscoper_expose_class('ErrorTest', 'BitPayVendor\ErrorTest'); humbug_phpscoper_expose_class('SecureRandomTest', 'BitPayVendor\SecureRandomTest'); humbug_phpscoper_expose_class('Base58Test', 'BitPayVendor\Base58Test');