Skip to content

Commit

Permalink
Keep types simple
Browse files Browse the repository at this point in the history
  • Loading branch information
Seldaek authored Apr 29, 2024
1 parent 1fafda1 commit 81f81b4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ClassMapGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,11 @@ public function getClassMap(): ClassMap
* @param non-empty-string|null $excluded Regex that matches file paths to be excluded from the classmap
* @param 'classmap'|'psr-0'|'psr-4' $autoloadType Optional autoload standard to use mapping rules with the namespace instead of purely doing a classmap
* @param string|null $namespace Optional namespace prefix to filter by, only for psr-0/psr-4 autoloading
* @param string|array<string> $excludedDirs Optional dirs to exclude from search relative to $path
* @param array<string> $excludedDirs Optional dirs to exclude from search relative to $path
*
* @throws \RuntimeException When the path is neither an existing file nor directory
*/
public function scanPaths($path, ?string $excluded = null, string $autoloadType = 'classmap', ?string $namespace = null, $excludedDirs = []): void
public function scanPaths($path, ?string $excluded = null, string $autoloadType = 'classmap', ?string $namespace = null, array $excludedDirs = []): void
{
if (!in_array($autoloadType, ['psr-0', 'psr-4', 'classmap'], true)) {
throw new \InvalidArgumentException('$autoloadType must be one of: "psr-0", "psr-4" or "classmap"');
Expand Down

0 comments on commit 81f81b4

Please sign in to comment.