Skip to content

Commit

Permalink
Merge pull request #87 from woocommerce/release/4.6.0
Browse files Browse the repository at this point in the history
Release/4.6.0
  • Loading branch information
dkotter authored Mar 27, 2024
2 parents 510704b + ecd9ebd commit 97f7165
Show file tree
Hide file tree
Showing 14 changed files with 51 additions and 33 deletions.
4 changes: 2 additions & 2 deletions .wp-env.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"core": null,
"plugins": [
".",
"https://downloads.wordpress.org/plugin/woocommerce.zip",
"https://downloads.wordpress.org/plugin/email-log.zip"
"https://downloads.wordpress.org/plugin/email-log.zip",
"."
],
"themes": [ "https://downloads.wordpress.org/theme/storefront.zip" ],
"env": {
Expand Down
11 changes: 10 additions & 1 deletion changelog.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
*** WooCommerce Square Changelog ***

= 4.5.2 - TBD =
= 4.6.0 - 2024-03-27 =
* Add - Support for buying a Square Gift Card using Cash App Pay.
* Add - Support for splitting payments between a Square Gift Card and Cash App Pay.
* Add - Support for the “Charge” and “Authorization” transaction types in the Cash App Pay payment method.
* Dev - Declare compatibility with PHP 8.3.
* Dev - Bump WooCommerce "tested up to" version 8.7.
* Dev - Bump WooCommerce minimum supported version to 8.5
* Dev - Bump WordPress "tested up to" version 6.5.
* Fix - Ensure a Gift Card is created when the Credit Card transaction type is "Authorization," and "Charge Virtual-Only Orders" is enabled.
* Fix - npm ERR! Missing script: "test:e2e".
* Fix - Issue with Square payment gateway being shown for unsupported currencies.

= 4.5.1 - 2024-02-27 =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ public function maybe_add_capture_charge_bulk_order_action() {
/**
* Adds 'Capture charge' to the Orders screen bulk action select (HPOS).
*
* @since x.x.x
* @since 4.6.0
*
* @param array $bulk_actions bulk actions
* @return array
Expand Down Expand Up @@ -222,7 +222,7 @@ public function maybe_add_capture_charge_bulk_actions( $bulk_actions ) {
/**
* Processes the 'Capture Charge' custom bulk action in HPOS.
*
* @since x.x.x
* @since 4.6.0
*/
public function hpos_process_capture_charge_bulk_order_action( $redirect_to, $action, $ids ) {
// bail if not processing a capture or if the user doesn't have the capability
Expand Down
22 changes: 11 additions & 11 deletions includes/Framework/PaymentGateway/Payment_Gateway.php
Original file line number Diff line number Diff line change
Expand Up @@ -1680,7 +1680,7 @@ public function get_order( $order ) {
/**
* Performs a transaction for the given order and returns the result.
*
* @since x.x.x
* @since 4.6.0
*
* @param WC_Order_Square $order the order object
* @param Create_Payment|null $response optional gateway transaction response
Expand Down Expand Up @@ -2116,7 +2116,7 @@ protected function maybe_tokenize( $response, $order ) {
*
* This method cancels gift card payment, and adds a relevant order note.
*
* @since x.x.x
* @since 4.6.0
*
* @param \WC_Order $order order object
* @param Payment_Gateway_API_Response $response response object
Expand Down Expand Up @@ -3461,7 +3461,7 @@ public function supports_credit_card_partial_capture() {
/**
* Returns true if gateway supports authorization transactions
*
* @since x.x.x
* @since 4.6.0
* @return boolean true if the gateway supports authorization
*/
public function supports_authorization() {
Expand All @@ -3472,7 +3472,7 @@ public function supports_authorization() {
/**
* Returns true if gateway supports charge transactions
*
* @since x.x.x
* @since 4.6.0
* @return boolean true if the gateway supports charges
*/
public function supports_charge() {
Expand All @@ -3483,7 +3483,7 @@ public function supports_charge() {
/**
* Determines if gateway supports charging virtual-only orders.
*
* @since x.x.x
* @since 4.6.0
* @return bool
*/
public function supports_charge_virtual() {
Expand All @@ -3494,7 +3494,7 @@ public function supports_charge_virtual() {
/**
* Returns true if the gateway supports capturing a charge
*
* @since x.x.x
* @since 4.6.0
* @return boolean true if the gateway supports capturing a charge
*/
public function supports_capture() {
Expand All @@ -3505,7 +3505,7 @@ public function supports_capture() {
/**
* Determines if the gateway supports capturing a partial charge.
*
* @since x.x.x
* @since 4.6.0
*
* @return bool
*/
Expand Down Expand Up @@ -3654,7 +3654,7 @@ public function perform_credit_card_authorization( \WC_Order $order = null ) {
/**
* Determines if a gateway transaction should result in a charge.
*
* @since x.x.x
* @since 4.6.0
*
* @param \WC_Order $order Optional. The order being charged
* @return bool
Expand All @@ -3672,7 +3672,7 @@ public function perform_charge( \WC_Order $order = null ) {
/**
* Filters whether a gateway transaction should result in a charge.
*
* @since x.x.x
* @since 4.6.0
*
* @param bool $perform whether the transaction should result in a charge
* @param \WC_Order|null $order the order being charged
Expand All @@ -3685,7 +3685,7 @@ public function perform_charge( \WC_Order $order = null ) {
/**
* Determines if a gateway transaction should result in an authorization.
*
* @since x.x.x
* @since 4.6.0
*
* @param \WC_Order $order Optional. The order being authorized
* @return bool
Expand Down Expand Up @@ -4579,7 +4579,7 @@ public function is_credit_card_gateway() {
/**
* Returns true if this is a Cash App Pay gateway
*
* @since x.x.x
* @since 4.6.0
* @return boolean true if this is a Cash App Pay gateway
*/
public function is_cash_app_pay_gateway() {
Expand Down
2 changes: 1 addition & 1 deletion includes/Gateway.php
Original file line number Diff line number Diff line change
Expand Up @@ -452,7 +452,7 @@ protected function do_transaction( $order ) {
/**
* Performs a credit card transaction for the given order and returns the result.
*
* @since x.x.x
* @since 4.6.0
*
* @param WC_Order_Square $order the order object
* @param Create_Payment|null $response optional credit card transaction response
Expand Down
6 changes: 3 additions & 3 deletions includes/Gateway/API.php
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ public function credit_card_charge( \WC_Order $order ) {
/**
* Performs a capture for a given authorized order.
*
* @since x.x.x
* @since 4.6.0
*
* @param \WC_Order $order order object
* @return \WooCommerce\Square\API\Response
Expand Down Expand Up @@ -166,7 +166,7 @@ public function gift_card_charge( \WC_Order $order ) {
/**
* Performs a cash app pay authorization for the given order.
*
* @since x.x.x
* @since 4.6.0
*
* @param \WC_Order $order order object
* @return \WooCommerce\Square\Gateway\API\Responses\Create_Payment
Expand Down Expand Up @@ -659,7 +659,7 @@ public function get_payment( $payment_id ) {
/**
* Cancel authorized payment.
*
* @since x.x.x
* @since 4.6.0
*
* @param string $payment_id transaction ID
* @return API\Responses\Create_Payment
Expand Down
2 changes: 1 addition & 1 deletion includes/Gateway/API/Requests/Payments.php
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ public function set_get_payment_data( $payment_id ) {
/**
* Sets the data for cancel a Payment.
*
* @since x.x.x
* @since 4.6.0
*
* @param string $payment_id payment ID
*/
Expand Down
2 changes: 1 addition & 1 deletion includes/Gateway/API/Responses/Create_Payment.php
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ public function is_cash_app_payment_completed() {
/**
* Returns true if the payment status is approved.
*
* @since x.x.x
* @since 4.6.0
* @return boolean
*/
public function is_cash_app_payment_approved() {
Expand Down
6 changes: 3 additions & 3 deletions includes/Gateway/Cash_App_Pay_Gateway.php
Original file line number Diff line number Diff line change
Expand Up @@ -542,7 +542,7 @@ public function get_order( $order_id ) {
/**
* Gets an order with capture data attached.
*
* @since x.x.x
* @since 4.6.0
*
* @param int|\WC_Order $order order object
* @param null|float $amount amount to capture
Expand Down Expand Up @@ -790,7 +790,7 @@ public function get_payment_request() {
* Get the partial amount to be paid by Cash App Pay.
* This is the amount after deducting the gift card balance.
*
* @since x.x.x
* @since 4.6.0
* @return float Partial amount to be paid by Cash App Pay.
*/
public function get_partial_cash_app_amount() {
Expand Down Expand Up @@ -1203,7 +1203,7 @@ protected function do_transaction( $order ) {
/**
* Performs a credit card transaction for the given order and returns the result.
*
* @since x.x.x
* @since 4.6.0
*
* @param WC_Order_Square $order the order object
* @param Create_Payment|null $response optional credit card transaction response
Expand Down
2 changes: 1 addition & 1 deletion includes/Handlers/Order.php
Original file line number Diff line number Diff line change
Expand Up @@ -664,7 +664,7 @@ public static function is_tender_type_gift_card( $order ) {
/**
* Returns if the order was placed using a Square cash app pay.
*
* @since x.x.x
* @since 4.6.0
*
* @param \WC_Order $order WooCommerce order.
*
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"url": "git://github.com/woocommerce/woocommerce-square.git"
},
"title": "WooCommerce Square",
"version": "4.5.1",
"version": "4.6.0",
"homepage": "https://woocommerce.com/products/woocommerce-square/",
"main": "Gruntfile.js",
"scripts": {
Expand Down
13 changes: 11 additions & 2 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Tags: credit card, square, woocommerce, inventory sync
Requires at least: 6.3
Tested up to: 6.5
Requires PHP: 7.4
Stable tag: 4.5.1
Stable tag: 4.6.0
License: GPL-3.0-or-later
License URI: https://www.gnu.org/licenses/gpl-3.0.html

Expand Down Expand Up @@ -75,7 +75,16 @@ If you get stuck, you can ask for help in the [Plugin Forum](https://wordpress.o

== Changelog ==

= 4.5.2 - TBD =
= 4.6.0 - 2024-03-27 =
* Add - Support for buying a Square Gift Card using Cash App Pay.
* Add - Support for splitting payments between a Square Gift Card and Cash App Pay.
* Add - Support for the “Charge” and “Authorization” transaction types in the Cash App Pay payment method.
* Dev - Declare compatibility with PHP 8.3.
* Dev - Bump WooCommerce "tested up to" version 8.7.
* Dev - Bump WooCommerce minimum supported version to 8.5
* Dev - Bump WordPress "tested up to" version 6.5.
* Fix - Ensure a Gift Card is created when the Credit Card transaction type is "Authorization," and "Charge Virtual-Only Orders" is enabled.
* Fix - npm ERR! Missing script: "test:e2e".
* Fix - Issue with Square payment gateway being shown for unsupported currencies.

= 4.5.1 - 2024-02-27 =
Expand Down
4 changes: 2 additions & 2 deletions woocommerce-square.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/**
* Plugin Name: WooCommerce Square
* Requires Plugins: woocommerce
* Version: 4.5.1
* Version: 4.6.0
* Plugin URI: https://woocommerce.com/products/square/
* Requires at least: 6.3
* Tested up to: 6.5
Expand All @@ -29,7 +29,7 @@
defined( 'ABSPATH' ) || exit;

if ( ! defined( 'WC_SQUARE_PLUGIN_VERSION' ) ) {
define( 'WC_SQUARE_PLUGIN_VERSION', '4.5.1' ); // WRCS: DEFINED_VERSION.
define( 'WC_SQUARE_PLUGIN_VERSION', '4.6.0' ); // WRCS: DEFINED_VERSION.
}

if ( ! defined( 'WC_SQUARE_PLUGIN_URL' ) ) {
Expand Down

0 comments on commit 97f7165

Please sign in to comment.