Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Commit

Permalink
Release: 7.4.3 (#6335)
Browse files Browse the repository at this point in the history
* Empty commit for release pull request

* Fix: Customizer fatal error for bundled woocommerce-blocks package (#6317)

* Add 7.4.3 changelog to readme.txt

* Release 7.4.3 testing instructions

* Bumping version strings to new version.

Co-authored-by: github-actions <[email protected]>
Co-authored-by: Tung Du <[email protected]>
Co-authored-by: tjcafferkey <[email protected]>
  • Loading branch information
4 people authored Apr 27, 2022
1 parent 03ab61b commit e450db4
Show file tree
Hide file tree
Showing 7 changed files with 36 additions and 6 deletions.
15 changes: 15 additions & 0 deletions docs/testing/releases/743.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
## Testing notes and ZIP for release 7.4.3

[woocommerce-gutenberg-products-block.zip](https://github.com/woocommerce/woocommerce-gutenberg-products-block/files/8570975/woocommerce-gutenberg-products-block.zip)


## Feature plugin and package inclusion in WooCommerce

#### Bug Fixes

### Fix Customizer fatal error on PHP 8. ([6317](https://github.com/woocommerce/woocommerce-gutenberg-products-block/pull/6317))

1. Using a site running on PHP 8.
2. Activate WC 6.5 beta 1 and Storefront.
4. Go to Appearance > Customize.
5. See no fatal error, the Customizer is loading and working as expected.
1 change: 1 addition & 0 deletions docs/testing/releases/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ Every release includes specific testing instructions for new features and bug fi
- [7.4.0](./740.md)
- [7.4.1](./741.md)
- [7.4.2](./742.md)
- [7.4.3](./743.md)

<!-- FEEDBACK -->
---
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@woocommerce/block-library",
"title": "WooCommerce Blocks",
"author": "Automattic",
"version": "7.4.2",
"version": "7.4.3",
"description": "WooCommerce blocks for the Gutenberg editor.",
"homepage": "https://github.com/woocommerce/woocommerce-gutenberg-products-block/",
"keywords": [
Expand Down
8 changes: 7 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Tags: gutenberg, woocommerce, woo commerce, products, blocks, woocommerce blocks
Requires at least: 5.9
Tested up to: 5.9
Requires PHP: 7.0
Stable tag: 7.4.2
Stable tag: 7.4.3
License: GPLv3
License URI: https://www.gnu.org/licenses/gpl-3.0.html

Expand Down Expand Up @@ -86,6 +86,12 @@ Release and roadmap notes available on the [WooCommerce Developers Blog](https:/

== Changelog ==

= 7.4.3 - 27-04-2022 =

#### Bug Fixes

- Fix Customizer fatal error on PHP 8. ([6317](https://github.com/woocommerce/woocommerce-gutenberg-products-block/pull/6317))

= 7.4.2 - 2022-04-15 =

#### Bug Fixes
Expand Down
12 changes: 10 additions & 2 deletions src/BlockTypes/MiniCart.php
Original file line number Diff line number Diff line change
Expand Up @@ -150,8 +150,14 @@ protected function enqueue_data( array $attributes = [] ) {
*
* $wp_scripts->print_translations() calls load_script_textdomain()
* which calls load_script_translations() containing the below filter.
*
* In Customzier, woocommerce_blocks_get_i18n_data_json doesn't exist
* at the time of this filter call. So we need checking for its
* existence to prevent fatal error.
*/
remove_filter( 'pre_load_script_translations', 'woocommerce_blocks_get_i18n_data_json', 10, 4 );
if ( function_exists( 'woocommerce_blocks_get_i18n_data_json' ) ) {
remove_filter( 'pre_load_script_translations', 'woocommerce_blocks_get_i18n_data_json', 10, 4 );
}

$script_data = $this->asset_api->get_script_data( 'build/mini-cart-component-frontend.js' );

Expand Down Expand Up @@ -187,7 +193,9 @@ protected function enqueue_data( array $attributes = [] ) {
);

// Re-add the filter.
add_filter( 'pre_load_script_translations', 'woocommerce_blocks_get_i18n_data_json', 10, 4 );
if ( function_exists( 'woocommerce_blocks_get_i18n_data_json' ) ) {
add_filter( 'pre_load_script_translations', 'woocommerce_blocks_get_i18n_data_json', 10, 4 );
}

$this->asset_data_registry->add(
'mini_cart_block_frontend_dependencies',
Expand Down
2 changes: 1 addition & 1 deletion src/Package.php
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ public static function container( $reset = false ) {
NewPackage::class,
function ( $container ) {
// leave for automated version bumping.
$version = '7.4.2';
$version = '7.4.3';
return new NewPackage(
$version,
dirname( __DIR__ ),
Expand Down
2 changes: 1 addition & 1 deletion woocommerce-gutenberg-products-block.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Plugin Name: WooCommerce Blocks
* Plugin URI: https://github.com/woocommerce/woocommerce-gutenberg-products-block
* Description: WooCommerce blocks for the Gutenberg editor.
* Version: 7.4.2
* Version: 7.4.3
* Author: Automattic
* Author URI: https://woocommerce.com
* Text Domain: woo-gutenberg-products-block
Expand Down

0 comments on commit e450db4

Please sign in to comment.