Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bug when plugin defines multiple PluginInterface classes #12226

Merged
merged 2 commits into from
Dec 10, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
PHP 5.3 array syntax
  • Loading branch information
justinbeaty committed Dec 7, 2024
commit 77ace687f457f8fae8cd1696508cb462327b4316
6 changes: 3 additions & 3 deletions src/Composer/Plugin/PluginManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ class PluginManager
protected $disablePlugins = false;

/** @var array<PluginInterface> */
protected $plugins = [];
protected $plugins = array();
/** @var array<string, array<PluginInterface|InstallerInterface>> */
protected $registeredPlugins = [];
protected $registeredPlugins = array();

/**
* @var array<non-empty-string, bool>|null
Expand Down Expand Up @@ -210,7 +210,7 @@ public function registerPackage(PackageInterface $package, $failOnMissingClasses
if (isset($this->registeredPlugins[$package->getName()])) {
return;
}
$this->registeredPlugins[$package->getName()] = [];
$this->registeredPlugins[$package->getName()] = array();

$extra = $package->getExtra();
if (empty($extra['class'])) {
Expand Down
Loading