From b7aeb01b7b2527e252e0ca015615cf46a2e54189 Mon Sep 17 00:00:00 2001 From: Evan Mullins Date: Wed, 14 Aug 2024 17:20:27 -0400 Subject: [PATCH 1/9] add temporary hook to filter an empty capabilites transient --- bootstrap.php | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/bootstrap.php b/bootstrap.php index f76b29e29..87bf0188a 100644 --- a/bootstrap.php +++ b/bootstrap.php @@ -203,3 +203,21 @@ function () { // Instantiate the Features singleton Features::getInstance(); + +/** + * Temporary hook to filter the capabilities in case they are empty + * This is to fix an issue where the migration value is not found on new sites + * Temporary fix to keep things working while we determing the root cause + */ +add_filter( + 'transient_nfd_site_capabilities', + function( $transient ) { + if( empty( $transient ) ) { + return array( + 'canMigrateSites' => true, + ); + } + }, + 10, + 2 +); From a76ae82c73427bc1b49f32bdd0b407e327d3a9de Mon Sep 17 00:00:00 2001 From: Evan Mullins Date: Wed, 14 Aug 2024 17:23:03 -0400 Subject: [PATCH 2/9] lint cleanup --- bootstrap.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/bootstrap.php b/bootstrap.php index 87bf0188a..accc5c3b7 100644 --- a/bootstrap.php +++ b/bootstrap.php @@ -211,13 +211,13 @@ function () { */ add_filter( 'transient_nfd_site_capabilities', - function( $transient ) { - if( empty( $transient ) ) { - return array( + function( $transient ) { + if( empty( $transient ) ) { + return array( 'canMigrateSites' => true, ); - } - }, - 10, - 2 + } + }, + 10, + 2 ); From 8398357b04084702c5cfa31a205f243b5570c1ec Mon Sep 17 00:00:00 2001 From: Evan Mullins Date: Wed, 14 Aug 2024 17:25:20 -0400 Subject: [PATCH 3/9] more lint --- bootstrap.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bootstrap.php b/bootstrap.php index accc5c3b7..961fa809d 100644 --- a/bootstrap.php +++ b/bootstrap.php @@ -211,8 +211,8 @@ function () { */ add_filter( 'transient_nfd_site_capabilities', - function( $transient ) { - if( empty( $transient ) ) { + function ( $transient ) { + if ( empty ( $transient ) ) { return array( 'canMigrateSites' => true, ); From efef44cde6678f0870917279c0e880b21457da7d Mon Sep 17 00:00:00 2001 From: Evan Mullins Date: Wed, 14 Aug 2024 17:26:17 -0400 Subject: [PATCH 4/9] whitespace --- bootstrap.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bootstrap.php b/bootstrap.php index 961fa809d..ba425164e 100644 --- a/bootstrap.php +++ b/bootstrap.php @@ -212,7 +212,7 @@ function () { add_filter( 'transient_nfd_site_capabilities', function ( $transient ) { - if ( empty ( $transient ) ) { + if ( empty( $transient ) ) { return array( 'canMigrateSites' => true, ); From 51372db32ea977cd199d098d0b00aef8ef13c805 Mon Sep 17 00:00:00 2001 From: Evan Mullins Date: Wed, 14 Aug 2024 17:46:05 -0400 Subject: [PATCH 5/9] fix typo in capability `canMigrateSite` --- bootstrap.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bootstrap.php b/bootstrap.php index ba425164e..8723869aa 100644 --- a/bootstrap.php +++ b/bootstrap.php @@ -214,7 +214,7 @@ function () { function ( $transient ) { if ( empty( $transient ) ) { return array( - 'canMigrateSites' => true, + 'canMigrateSite' => true, ); } }, From 0f2d541c3550219436970f7c5b5d252e0172ca4d Mon Sep 17 00:00:00 2001 From: Evan Mullins Date: Wed, 14 Aug 2024 17:47:56 -0400 Subject: [PATCH 6/9] update plugin version to 3.14.3 --- bluehost-wordpress-plugin.php | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bluehost-wordpress-plugin.php b/bluehost-wordpress-plugin.php index ccc2a900a..e7b381cb6 100644 --- a/bluehost-wordpress-plugin.php +++ b/bluehost-wordpress-plugin.php @@ -12,7 +12,7 @@ * Plugin URI: https://bluehost.com * Update URI: https://github.com/bluehost/bluehost-wordpress-plugin * Description: WordPress plugin that integrates a WordPress site with the Bluehost control panel, including performance, security, and update features. - * Version: 3.14.2 + * Version: 3.14.3 * Requires at least: 6.4 * Requires PHP: 7.3 * Tested up to: 6.6.1 @@ -32,7 +32,7 @@ } // Define constants -define( 'BLUEHOST_PLUGIN_VERSION', '3.14.2' ); +define( 'BLUEHOST_PLUGIN_VERSION', '3.14.3' ); define( 'BLUEHOST_PLUGIN_FILE', __FILE__ ); define( 'BLUEHOST_PLUGIN_DIR', plugin_dir_path( __FILE__ ) ); define( 'BLUEHOST_PLUGIN_URL', plugin_dir_url( __FILE__ ) ); diff --git a/package.json b/package.json index bcde71d80..eae7a9ca6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "bluehost-wordpress-plugin", - "version": "3.14.2", + "version": "3.14.3", "description": "WordPress plugin that integrates your WordPress site with the Bluehost control panel, including performance, security, and update features.", "author": { "name": "Bluehost", From a5a3a2dfe44b0fc6904166d42297774218cc1ab8 Mon Sep 17 00:00:00 2001 From: Evan Mullins Date: Wed, 14 Aug 2024 17:49:14 -0400 Subject: [PATCH 7/9] run `npm audit fix` --- package-lock.json | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/package-lock.json b/package-lock.json index f8e73256f..23ebed68e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "bluehost-wordpress-plugin", - "version": "3.14.2", + "version": "3.14.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "bluehost-wordpress-plugin", - "version": "3.14.2", + "version": "3.14.3", "license": "GPL-2.0-or-later", "dependencies": { "@heroicons/react": "^2.1.5", @@ -7255,9 +7255,9 @@ } }, "node_modules/axios": { - "version": "1.6.8", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.6.8.tgz", - "integrity": "sha512-v/ZHtJDU39mDpyBoFVkETcd/uNdxrWRrg3bKpOKzXFA6Bvqopts6ALSMU3y6ijYxbw2B+wPrIv46egTzJXCLGQ==", + "version": "1.7.4", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.7.4.tgz", + "integrity": "sha512-DukmaFRnY6AzAALSH4J2M3k6PkaC+MfaAGdEERRWcC9q3/TWQwLpHR8ZRLKTdQ3aBDL64EdluRDjJqKw+BPZEw==", "dev": true, "dependencies": { "follow-redirects": "^1.15.6", From 6014b6af28b8d9671af7563645f802dd3c5abfed Mon Sep 17 00:00:00 2001 From: Evan Mullins Date: Wed, 14 Aug 2024 17:51:34 -0400 Subject: [PATCH 8/9] run `composer run i18n` to update i18n pot file --- languages/wp-plugin-bluehost.pot | 130 ++++++++++++++++--------------- 1 file changed, 67 insertions(+), 63 deletions(-) diff --git a/languages/wp-plugin-bluehost.pot b/languages/wp-plugin-bluehost.pot index de67d6639..73b1b8cda 100644 --- a/languages/wp-plugin-bluehost.pot +++ b/languages/wp-plugin-bluehost.pot @@ -2,7 +2,7 @@ # This file is distributed under the GPL 2.0 or later. msgid "" msgstr "" -"Project-Id-Version: The Bluehost Plugin 3.13.0\n" +"Project-Id-Version: The Bluehost Plugin 3.14.3\n" "Report-Msgid-Bugs-To: https://github.com/bluehost/bluehost-wordpress-plugin/issues\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -86,43 +86,43 @@ msgstr "" #: inc/Admin.php:70 #: inc/Admin.php:276 -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Home" msgstr "" #: inc/Admin.php:73 -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Pages & Posts" msgstr "" #: inc/Admin.php:76 -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Store" msgstr "" #: inc/Admin.php:79 -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Marketplace" msgstr "" #: inc/Admin.php:84 -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Performance" msgstr "" #: inc/Admin.php:88 #: inc/Admin.php:277 -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Settings" msgstr "" #: inc/Admin.php:93 -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Staging" msgstr "" #: inc/Admin.php:97 -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Help" msgstr "" @@ -192,220 +192,224 @@ msgstr "" msgid "Auto-updates enabled" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Bluehost WordPress Plugin" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Oh No, An Error!" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "You found an error, please refresh the page and try again!" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "If the error persists, please contact support." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid " Error code: " msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Bluehost Account" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "There's nothing here!" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Products & Services" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Sales & Promotions" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 +msgid "Sales Channel" +msgstr "" + +#: build/3.14.3/index.js:1 msgid "Payments" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Store Details" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Admin" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "The staging feature provides a way to copy a site to test new updates, features or content." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Sorry, that is not allowed." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "This feature cannot currently be modified." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Oops! Something went wrong. Please try again." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Phone" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Call Us" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Chat" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Chat with one of our friendly Customer Care Specialists, as we are waiting to help. Open 24 hours - 7 days." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Live Chat" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Tweet" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Find our team at @bluehost for updates on our products and support from our team." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Tweet Us" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "YouTube" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Find tutorials, answers, interviews and guides on our YouTube channel." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Watch Now" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Knowledge Base" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Articles, guides, how-tos, instructions, and answers to our client's most frequently asked questions." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Visit Knowledge Base" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Resources" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Boost your online knowledge and get ahead of the competition." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Explore Resources" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Events and Webinars" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Team Bluehost organizes multiple webinars and events throughout the year. We are also sponsors and speak at most WordCamps across the world. Join us at our next event!" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "More Info" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Bluehost Website" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Not finding what you need? Visit our website for more information about our products and services." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Go to Bluehost" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Site Pages" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Edit your homepage and other existing pages or add new pages to your site." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "View all" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Add New" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "The Help Center provides guided, step-by-step assistance as you build your site." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Site Status" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Not Live" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Live" msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Your Bluehost Coming Soon page lets you hide your site from visitors while you make the magic happen." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid "Your website is currently displaying a \"Coming Soon\" page." msgstr "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid " revision." msgid_plural " revisions." msgstr[0] "" msgstr[1] "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid " step back." msgid_plural " steps back." msgstr[0] "" msgstr[1] "" -#: build/3.13.0/index.js:1 +#: build/3.14.3/index.js:1 msgid " week." msgid_plural " weeks." msgstr[0] "" msgstr[1] "" -#: build/3.13.0/index.js:1 -msgid "Wonder Blocks provides a library of customizable block patterns and page templates." +#: build/3.14.3/index.js:1 +msgid "WonderBlocks provides a library of customizable block patterns and page templates." msgstr "" From fedddac3dd4276b44e63cafdb0b3b925a019b9b1 Mon Sep 17 00:00:00 2001 From: Evan Mullins Date: Wed, 14 Aug 2024 18:14:46 -0400 Subject: [PATCH 9/9] return the transient if not empty! --- bootstrap.php | 1 + 1 file changed, 1 insertion(+) diff --git a/bootstrap.php b/bootstrap.php index 8723869aa..a4470c102 100644 --- a/bootstrap.php +++ b/bootstrap.php @@ -217,6 +217,7 @@ function ( $transient ) { 'canMigrateSite' => true, ); } + return $transient; }, 10, 2