Skip to content

Commit 6e04105

Browse files
SP-702 WooCommerce - PHP 8.0
1 parent 3c519d7 commit 6e04105

File tree

911 files changed

+340
-366
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

911 files changed

+340
-366
lines changed

BitPayLib/class-bitpaycancelorder.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Plugin Name: BitPay Checkout for WooCommerce
99
* Plugin URI: https://www.bitpay.com
1010
* Description: BitPay Checkout Plugin
11-
* Version: 5.2.0
11+
* Version: 5.3.0
1212
* Author: BitPay
1313
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1414
*/

BitPayLib/class-bitpaycart.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Plugin Name: BitPay Checkout for WooCommerce
99
* Plugin URI: https://www.bitpay.com
1010
* Description: BitPay Checkout Plugin
11-
* Version: 5.2.0
11+
* Version: 5.3.0
1212
* Author: BitPay
1313
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1414
*/

BitPayLib/class-bitpaycheckouttransactions.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* Plugin Name: BitPay Checkout for WooCommerce
1212
* Plugin URI: https://www.bitpay.com
1313
* Description: BitPay Checkout Plugin
14-
* Version: 5.2.0
14+
* Version: 5.3.0
1515
* Author: BitPay
1616
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1717
*/

BitPayLib/class-bitpayclientfactory.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
* Plugin Name: BitPay Checkout for WooCommerce
1414
* Plugin URI: https://www.bitpay.com
1515
* Description: BitPay Checkout Plugin
16-
* Version: 5.2.0
16+
* Version: 5.3.0
1717
* Author: BitPay
1818
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1919
*/

BitPayLib/class-bitpayinvoicecreate.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
* Plugin Name: BitPay Checkout for WooCommerce
1414
* Plugin URI: https://www.bitpay.com
1515
* Description: BitPay Checkout Plugin
16-
* Version: 5.2.0
16+
* Version: 5.3.0
1717
* Author: BitPay
1818
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1919
*/

BitPayLib/class-bitpayipnprocess.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
* Plugin Name: BitPay Checkout for WooCommerce
1414
* Plugin URI: https://www.bitpay.com
1515
* Description: BitPay Checkout Plugin
16-
* Version: 5.2.0
16+
* Version: 5.3.0
1717
* Author: BitPay
1818
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1919
*/

BitPayLib/class-bitpaylogger.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Plugin Name: BitPay Checkout for WooCommerce
99
* Plugin URI: https://www.bitpay.com
1010
* Description: BitPay Checkout Plugin
11-
* Version: 5.2.0
11+
* Version: 5.3.0
1212
* Author: BitPay
1313
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1414
*/

BitPayLib/class-bitpaypages.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
/**
88
* Plugin Name: BitPay Checkout for WooCommerce
99
* Plugin URI: https://www.bitpay.com
10-
* Version: 5.2.0
10+
* Version: 5.3.0
1111
* Author: BitPay
1212
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1313
*/

BitPayLib/class-bitpaypaymentsettings.php

+1-14
Original file line numberDiff line numberDiff line change
@@ -8,25 +8,12 @@
88
* Plugin Name: BitPay Checkout for WooCommerce
99
* Plugin URI: https://www.bitpay.com
1010
* Description: BitPay Checkout Plugin
11-
* Version: 5.2.0
11+
* Version: 5.3.0
1212
* Author: BitPay
1313
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1414
*/
1515
class BitPayPaymentSettings {
1616

17-
public function define_payment_gateway(): void {
18-
if ( is_checkout() && ! is_wc_endpoint_url() ) {
19-
global $woocommerce;
20-
$bitpay_checkout_options = get_option( 'woocommerce_bitpay_checkout_gateway_settings' );
21-
$bitpay_checkout_product = $bitpay_checkout_options['bitpay_checkout_product'];
22-
$default_payment_id = 'bitpay_checkout_gateway';
23-
24-
if ( (int) $bitpay_checkout_product === 1 && isset( $_GET['payment'] ) && $_GET['payment'] === 'bitpay' ) { // phpcs:ignore
25-
WC()->session->set( 'chosen_payment_method', $default_payment_id );
26-
}
27-
}
28-
}
29-
3017
public function wc_bitpay_checkout_add_to_gateways( array $gateways ): array {
3118
$gateways[] = new WcGatewayBitpay();
3219
return $gateways;

BitPayLib/class-bitpaypluginsetup.php

+1-6
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* Plugin Name: BitPay Checkout for WooCommerce
1111
* Plugin URI: https://www.bitpay.com
1212
* Description: BitPay Checkout Plugin
13-
* Version: 5.2.0
13+
* Version: 5.3.0
1414
* Author: BitPay
1515
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1616
*/
@@ -43,7 +43,6 @@ public function execute(): void {
4343
register_activation_hook( __FILE__, array( $this, 'add_error_page' ) );
4444

4545
add_action( 'plugins_loaded', array( $this, 'validate_wc_payment_gateway' ), 11 );
46-
add_action( 'template_redirect', array( $this, 'bitpay_default_payment_gateway' ) );
4746
add_action( 'woocommerce_widget_shopping_cart_buttons', array( $this, 'bitpay_mini_checkout' ), 20 );
4847
add_action( 'template_redirect', array( $this, 'create_bitpay_invoice' ) );
4948
add_action( 'admin_notices', array( $this, 'update_db' ) );
@@ -136,10 +135,6 @@ public function validate_wc_payment_gateway(): void {
136135
}
137136
}
138137

139-
public function bitpay_default_payment_gateway(): void {
140-
$this->bitpay_payment_settings->define_payment_gateway();
141-
}
142-
143138
public function bitpay_mini_checkout(): void {
144139
$this->bitpay_payment_settings->bitpay_mini_checkout();
145140
}

BitPayLib/class-wcgatewaybitpay.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Plugin Name: BitPay Checkout for WooCommerce
99
* Plugin URI: https://www.bitpay.com
1010
* Description: BitPay Checkout Plugin
11-
* Version: 5.2.0
11+
* Version: 5.3.0
1212
* Author: BitPay
1313
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1414
*/

BitPayLib/trait-wpdbhelper.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* Plugin Name: BitPay Checkout for WooCommerce
1111
* Plugin URI: https://www.bitpay.com
1212
* Description: BitPay Checkout Plugin
13-
* Version: 5.2.0
13+
* Version: 5.3.0
1414
* Author: BitPay
1515
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1616
*/

CHANGELOG.md

+4

README.md

+1-1

vendorPrefixed/BitPayLib/class-bitpaycancelorder.php build/BitPayLib/class-bitpaycancelorder.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Plugin Name: BitPay Checkout for WooCommerce
88
* Plugin URI: https://www.bitpay.com
99
* Description: BitPay Checkout Plugin
10-
* Version: 5.2.0
10+
* Version: 5.3.0
1111
* Author: BitPay
1212
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1313
*/

vendorPrefixed/BitPayLib/class-bitpaycart.php build/BitPayLib/class-bitpaycart.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Plugin Name: BitPay Checkout for WooCommerce
88
* Plugin URI: https://www.bitpay.com
99
* Description: BitPay Checkout Plugin
10-
* Version: 5.2.0
10+
* Version: 5.3.0
1111
* Author: BitPay
1212
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1313
*/

vendorPrefixed/BitPayLib/class-bitpaycheckouttransactions.php build/BitPayLib/class-bitpaycheckouttransactions.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
* Plugin Name: BitPay Checkout for WooCommerce
1010
* Plugin URI: https://www.bitpay.com
1111
* Description: BitPay Checkout Plugin
12-
* Version: 5.2.0
12+
* Version: 5.3.0
1313
* Author: BitPay
1414
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1515
*/

vendorPrefixed/BitPayLib/class-bitpayclientfactory.php build/BitPayLib/class-bitpayclientfactory.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* Plugin Name: BitPay Checkout for WooCommerce
1212
* Plugin URI: https://www.bitpay.com
1313
* Description: BitPay Checkout Plugin
14-
* Version: 5.2.0
14+
* Version: 5.3.0
1515
* Author: BitPay
1616
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1717
*/

vendorPrefixed/BitPayLib/class-bitpayinvoicecreate.php build/BitPayLib/class-bitpayinvoicecreate.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* Plugin Name: BitPay Checkout for WooCommerce
1212
* Plugin URI: https://www.bitpay.com
1313
* Description: BitPay Checkout Plugin
14-
* Version: 5.2.0
14+
* Version: 5.3.0
1515
* Author: BitPay
1616
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1717
*/

vendorPrefixed/BitPayLib/class-bitpayipnprocess.php build/BitPayLib/class-bitpayipnprocess.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* Plugin Name: BitPay Checkout for WooCommerce
1212
* Plugin URI: https://www.bitpay.com
1313
* Description: BitPay Checkout Plugin
14-
* Version: 5.2.0
14+
* Version: 5.3.0
1515
* Author: BitPay
1616
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1717
*/

vendorPrefixed/BitPayLib/class-bitpaylogger.php build/BitPayLib/class-bitpaylogger.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Plugin Name: BitPay Checkout for WooCommerce
88
* Plugin URI: https://www.bitpay.com
99
* Description: BitPay Checkout Plugin
10-
* Version: 5.2.0
10+
* Version: 5.3.0
1111
* Author: BitPay
1212
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1313
*/

vendorPrefixed/BitPayLib/class-bitpaypages.php build/BitPayLib/class-bitpaypages.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
/**
77
* Plugin Name: BitPay Checkout for WooCommerce
88
* Plugin URI: https://www.bitpay.com
9-
* Version: 5.2.0
9+
* Version: 5.3.0
1010
* Author: BitPay
1111
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1212
*/

vendorPrefixed/BitPayLib/class-bitpaypaymentsettings.php build/BitPayLib/class-bitpaypaymentsettings.php

+1-14
Original file line numberDiff line numberDiff line change
@@ -7,25 +7,12 @@
77
* Plugin Name: BitPay Checkout for WooCommerce
88
* Plugin URI: https://www.bitpay.com
99
* Description: BitPay Checkout Plugin
10-
* Version: 5.2.0
10+
* Version: 5.3.0
1111
* Author: BitPay
1212
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1313
*/
1414
class BitPayPaymentSettings
1515
{
16-
public function define_payment_gateway() : void
17-
{
18-
if (is_checkout() && !is_wc_endpoint_url()) {
19-
global $woocommerce;
20-
$bitpay_checkout_options = get_option('woocommerce_bitpay_checkout_gateway_settings');
21-
$bitpay_checkout_product = $bitpay_checkout_options['bitpay_checkout_product'];
22-
$default_payment_id = 'bitpay_checkout_gateway';
23-
if ((int) $bitpay_checkout_product === 1 && isset($_GET['payment']) && $_GET['payment'] === 'bitpay') {
24-
// phpcs:ignore
25-
WC()->session->set('chosen_payment_method', $default_payment_id);
26-
}
27-
}
28-
}
2916
public function wc_bitpay_checkout_add_to_gateways(array $gateways) : array
3017
{
3118
$gateways[] = new WcGatewayBitpay();

vendorPrefixed/BitPayLib/class-bitpaypluginsetup.php build/BitPayLib/class-bitpaypluginsetup.php

+1-6
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Plugin Name: BitPay Checkout for WooCommerce
99
* Plugin URI: https://www.bitpay.com
1010
* Description: BitPay Checkout Plugin
11-
* Version: 5.2.0
11+
* Version: 5.3.0
1212
* Author: BitPay
1313
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1414
*/
@@ -35,7 +35,6 @@ public function execute() : void
3535
register_activation_hook(__FILE__, array($this, 'setup_plugin'));
3636
register_activation_hook(__FILE__, array($this, 'add_error_page'));
3737
add_action('plugins_loaded', array($this, 'validate_wc_payment_gateway'), 11);
38-
add_action('template_redirect', array($this, 'bitpay_default_payment_gateway'));
3938
add_action('woocommerce_widget_shopping_cart_buttons', array($this, 'bitpay_mini_checkout'), 20);
4039
add_action('template_redirect', array($this, 'create_bitpay_invoice'));
4140
add_action('admin_notices', array($this, 'update_db'));
@@ -101,10 +100,6 @@ public function validate_wc_payment_gateway() : void
101100
}
102101
}
103102
}
104-
public function bitpay_default_payment_gateway() : void
105-
{
106-
$this->bitpay_payment_settings->define_payment_gateway();
107-
}
108103
public function bitpay_mini_checkout() : void
109104
{
110105
$this->bitpay_payment_settings->bitpay_mini_checkout();

vendorPrefixed/BitPayLib/class-wcgatewaybitpay.php build/BitPayLib/class-wcgatewaybitpay.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Plugin Name: BitPay Checkout for WooCommerce
88
* Plugin URI: https://www.bitpay.com
99
* Description: BitPay Checkout Plugin
10-
* Version: 5.2.0
10+
* Version: 5.3.0
1111
* Author: BitPay
1212
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1313
*/

vendorPrefixed/BitPayLib/trait-wpdbhelper.php build/BitPayLib/trait-wpdbhelper.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Plugin Name: BitPay Checkout for WooCommerce
99
* Plugin URI: https://www.bitpay.com
1010
* Description: BitPay Checkout Plugin
11-
* Version: 5.2.0
11+
* Version: 5.3.0
1212
* Author: BitPay
1313
* Author URI: mailto:[email protected]?subject=BitPay Checkout for WooCommerce
1414
*/

vendorPrefixed/composer.json build/composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
"scripts": {
2323
"add-prefix": [
2424
"php php-scoper.phar add-prefix --force --quiet",
25-
"composer dump-autoload --working-dir vendorPrefixed"
25+
"composer dump-autoload --working-dir build"
2626
],
2727
"dump-prefixed-vendor": "composer dump-autoload --working-dir vendorPrefixed --classmap-authoritative",
2828
"post-install-cmd": [

vendorPrefixed/vendor/autoload.php build/vendor/autoload.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,4 @@
2222

2323
require_once __DIR__ . '/composer/autoload_real.php';
2424

25-
return ComposerAutoloaderInitffe20d458e05e78e2995f3c4709720b3::getLoader();
25+
return ComposerAutoloaderInit525433e856ed0d2b0814b35e13f966c3::getLoader();
File renamed without changes.

0 commit comments

Comments
 (0)