diff --git a/php-templates/configs.php b/php-templates/configs.php index 4c9ec70d..a7c02750 100644 --- a/php-templates/configs.php +++ b/php-templates/configs.php @@ -1,7 +1,8 @@ merge(glob(config_path("**/*.php"))) +$local = collect(\Illuminate\Support\Facades\File::allFiles(config_path())) + ->filter(fn(\Symfony\Component\Finder\SplFileInfo $file) => $file->getExtension() === 'php') + ->map(fn (\Symfony\Component\Finder\SplFileInfo $file) => $file->getPathname()) ->map(fn ($path) => [ (string) str($path) ->replace([config_path('/'), ".php"], "") diff --git a/src/templates/configs.ts b/src/templates/configs.ts index 7a641be7..d48e9199 100644 --- a/src/templates/configs.ts +++ b/src/templates/configs.ts @@ -1,7 +1,8 @@ // This file was generated from php-templates/configs.php, do not edit directly export default ` -$local = collect(glob(config_path("/*.php"))) - ->merge(glob(config_path("**/*.php"))) +$local = collect(\\Illuminate\\Support\\Facades\\File::allFiles(config_path())) + ->filter(fn(\\Symfony\\Component\\Finder\\SplFileInfo $file) => $file->getExtension() === 'php') + ->map(fn (\\Symfony\\Component\\Finder\\SplFileInfo $file) => $file->getPathname()) ->map(fn ($path) => [ (string) str($path) ->replace([config_path('/'), ".php"], "")