Skip to content

Commit 708d816

Browse files
committed
use str finish
1 parent 7f00a2d commit 708d816

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/Illuminate/Database/Console/Factories/FactoryMakeCommand.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Illuminate\Database\Console\Factories;
44

55
use Illuminate\Console\GeneratorCommand;
6+
use Illuminate\Support\Str;
67
use Symfony\Component\Console\Input\InputOption;
78

89
class FactoryMakeCommand extends GeneratorCommand
@@ -91,6 +92,8 @@ protected function getPath($name)
9192
['\\', '/'], '', $this->argument('name')
9293
);
9394

95+
$name = Str::finish($name, 'Factory');
96+
9497
return $this->laravel->databasePath()."/factories/{$name}.php";
9598
}
9699

0 commit comments

Comments
 (0)