From bb3eb3ae7721f041d48d4117dfe27934226c9a64 Mon Sep 17 00:00:00 2001 From: Sean Fisher Date: Wed, 14 Feb 2024 09:11:17 -0500 Subject: [PATCH 1/3] Change the class namespace --- CHANGELOG.md | 5 +++++ composer.json | 2 +- src/class-wp-plugin-loader.php | 5 ++++- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9004c04..d06cb99 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to `WP Plugin Loader` will be documented in this file. +## 0.1.2 - 2024-02-14 + +- Changes class from `Alley\WP\WP_Plugin_Loader\WP_Plugin_Loader` to + `Alley\WP_Plugin_Loader`. + ## 0.1.1 - 2023-07-24 - Added APCu caching for plugin folder lookups. diff --git a/composer.json b/composer.json index aa52e7c..130fb5e 100644 --- a/composer.json +++ b/composer.json @@ -19,7 +19,7 @@ "alleyinteractive/composer-wordpress-autoloader": "^1.0" }, "require-dev": { - "alleyinteractive/alley-coding-standards": "^1.0", + "alleyinteractive/alley-coding-standards": "^2.0", "szepeviktor/phpstan-wordpress": "^1.1" }, "config": { diff --git a/src/class-wp-plugin-loader.php b/src/class-wp-plugin-loader.php index 882df98..4fcf489 100644 --- a/src/class-wp-plugin-loader.php +++ b/src/class-wp-plugin-loader.php @@ -5,7 +5,7 @@ * @package wp-plugin-loader */ -namespace Alley\WP\WP_Plugin_Loader; +namespace Alley\WP; /** * WordPress Plugin Loader @@ -290,3 +290,6 @@ public function prevent_plugin_activation( $caps, $cap ) { return $caps; } } + +// Include an alias for legacy references to the former class namespace. +class_alias( WP_Plugin_Loader::class, 'Alley\WP\WP_Plugin_Loader\WP_Plugin_Loader' ); From b93a9154df5e029c6214e541e99a1a1404b7704d Mon Sep 17 00:00:00 2001 From: Sean Fisher Date: Wed, 14 Feb 2024 09:25:26 -0500 Subject: [PATCH 2/3] Update CHANGELOG.md Co-authored-by: Greg Marshall --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6d1b2b8..864cd87 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,7 @@ All notable changes to `WP Plugin Loader` will be documented in this file. ## 0.1.2 - 2024-02-14 - Changes class from `Alley\WP\WP_Plugin_Loader\WP_Plugin_Loader` to - `Alley\WP_Plugin_Loader`. + `Alley\WP\WP_Plugin_Loader`. - Account for some one-off plugins that don't follow the standard naming conventions. ## 0.1.1 - 2023-07-24 From 1b980fff871eff023f64e94f24b94ec8541e4c4b Mon Sep 17 00:00:00 2001 From: Sean Fisher Date: Wed, 14 Feb 2024 09:26:30 -0500 Subject: [PATCH 3/3] CHANGELOG --- CHANGELOG.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 864cd87..106c21d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,12 +2,16 @@ All notable changes to `WP Plugin Loader` will be documented in this file. -## 0.1.2 - 2024-02-14 +## 0.1.3 - 2024-02-14 - Changes class from `Alley\WP\WP_Plugin_Loader\WP_Plugin_Loader` to `Alley\WP\WP_Plugin_Loader`. - Account for some one-off plugins that don't follow the standard naming conventions. +# 0.1.2 - 2023-07-25 + +- Ensure a plugin can be discovered from mu-plugins on a non-VIP environment. + ## 0.1.1 - 2023-07-24 - Added APCu caching for plugin folder lookups.