From 14e959cd85b2092e560ffe91d68a39bc497e892e Mon Sep 17 00:00:00 2001 From: Julius Kiekbusch Date: Mon, 27 Sep 2021 15:21:57 +0200 Subject: [PATCH] Only look for files ending with .php in model:prune (#38975) --- src/Illuminate/Database/Console/PruneCommand.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Illuminate/Database/Console/PruneCommand.php b/src/Illuminate/Database/Console/PruneCommand.php index 9aa9f62923e8..d84b0a01517f 100644 --- a/src/Illuminate/Database/Console/PruneCommand.php +++ b/src/Illuminate/Database/Console/PruneCommand.php @@ -87,7 +87,7 @@ protected function models() return collect($models); } - return collect((new Finder)->in(app_path('Models'))->files()) + return collect((new Finder)->in(app_path('Models'))->files()->name('*.php')) ->map(function ($model) { $namespace = $this->laravel->getNamespace();