11<?php
2- declare (strict_types=1 );
3-
42namespace Cake \Composer ;
53
64use Composer \Composer ;
@@ -88,8 +86,8 @@ public function postAutoloadDump(Event $event)
8886 public function findPlugins (
8987 array $ packages ,
9088 array $ pluginDirs = ['plugins ' ],
91- string $ vendorDir = 'vendor '
92- ): array {
89+ $ vendorDir = 'vendor '
90+ ) {
9391 $ plugins = [];
9492
9593 foreach ($ packages as $ package ) {
@@ -133,7 +131,7 @@ public function findPlugins(
133131 * @param string $vendorDir The path to the vendor dir.
134132 * @return string
135133 */
136- public function getFullPath (string $ path , string $ vendorDir ): string
134+ public function getFullPath ($ path , $ vendorDir )
137135 {
138136 if (preg_match ('{^(?:/|[a-z]:|[a-z0-9.]+://)}i ' , $ path )) {
139137 return rtrim ($ path , '/ ' );
@@ -154,7 +152,7 @@ public function getFullPath(string $path, string $vendorDir): string
154152 * @param string|null $root The root directory. Defaults to a value generated from `$configFile`.
155153 * @return void
156154 */
157- public function writeConfigFile (string $ configFile , array $ plugins , ? string $ root = null ): void
155+ public function writeConfigFile ($ configFile , array $ plugins , $ root = null )
158156 {
159157 $ root = $ root ?: dirname (dirname ($ configFile ));
160158
@@ -214,7 +212,7 @@ public function writeConfigFile(string $configFile, array $plugins, ?string $roo
214212 * @param string $vendorDir Path to composer-vendor dir.
215213 * @return string Absolute file path.
216214 */
217- public function getConfigFilePath (string $ vendorDir ): string
215+ public function getConfigFilePath ($ vendorDir )
218216 {
219217 return $ vendorDir . DIRECTORY_SEPARATOR . 'cakephp-plugins.php ' ;
220218 }
@@ -226,7 +224,7 @@ public function getConfigFilePath(string $vendorDir): string
226224 * @return string The package's primary namespace.
227225 * @throws \RuntimeException When the package's primary namespace cannot be determined.
228226 */
229- public function getPrimaryNamespace (PackageInterface $ package ): string
227+ public function getPrimaryNamespace (PackageInterface $ package )
230228 {
231229 $ primaryNs = null ;
232230 $ autoLoad = $ package ->getAutoload ();
0 commit comments