Skip to content

Commit 59f7262

Browse files
committed
chore: fix php-cs
1 parent 2192533 commit 59f7262

File tree

3 files changed

+11
-10
lines changed

3 files changed

+11
-10
lines changed

src/core/src/ConfigProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@
1818
use Hyperf\ViewEngine\Compiler\CompilerInterface;
1919
use Hypervel\Database\Console\SeedCommand;
2020
use Hypervel\Database\Eloquent\Factories\FactoryInvoker as DatabaseFactoryInvoker;
21-
use Hypervel\Database\Migrations\MigrationCreator as HyperfMigrationCreator;
2221
use Hypervel\Database\Migrations\MigrationCreator;
22+
use Hypervel\Database\Migrations\MigrationCreator as HyperfMigrationCreator;
2323
use Hypervel\Database\TransactionListener;
2424
use Hypervel\Redis\RedisPool;
2525
use Hypervel\View\CompilerFactory;

src/core/src/Database/Console/SeedCommand.php

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@
1616

1717
class SeedCommand extends Command
1818
{
19-
use ConfirmableTrait, Prohibitable;
19+
use ConfirmableTrait;
20+
use Prohibitable;
2021

2122
/**
2223
* The console command name.
@@ -31,7 +32,7 @@ class SeedCommand extends Command
3132
/**
3233
* Create a new database seed command instance.
3334
*
34-
* @param ConnectionResolverInterface $resolver The connection resolver instance.
35+
* @param ConnectionResolverInterface $resolver the connection resolver instance
3536
*/
3637
public function __construct(
3738
protected ConnectionResolverInterface $resolver
@@ -44,8 +45,8 @@ public function __construct(
4445
*/
4546
public function handle(): int
4647
{
47-
if ($this->isProhibited() ||
48-
! $this->confirmToProceed()
48+
if ($this->isProhibited()
49+
|| ! $this->confirmToProceed()
4950
) {
5051
return Command::FAILURE;
5152
}
@@ -75,10 +76,10 @@ protected function getSeeder(): Seeder
7576
$class = $this->input->getArgument('class') ?? $this->input->getOption('class');
7677

7778
if (! str_contains($class, '\\')) {
78-
$class = 'Database\\Seeders\\' . $class;
79+
$class = 'Database\Seeders\\' . $class;
7980
}
8081

81-
if ($class === 'Database\\Seeders\\DatabaseSeeder'
82+
if ($class === 'Database\Seeders\DatabaseSeeder'
8283
&& ! class_exists($class)) {
8384
$class = 'DatabaseSeeder';
8485
}
@@ -116,7 +117,7 @@ protected function getArguments(): array
116117
protected function getOptions(): array
117118
{
118119
return [
119-
['class', null, InputOption::VALUE_OPTIONAL, 'The class name of the root seeder', 'Database\\Seeders\\DatabaseSeeder'],
120+
['class', null, InputOption::VALUE_OPTIONAL, 'The class name of the root seeder', 'Database\Seeders\DatabaseSeeder'],
120121
['database', null, InputOption::VALUE_OPTIONAL, 'The database connection to seed'],
121122
['force', null, InputOption::VALUE_NONE, 'Force the operation to run when in production'],
122123
];

src/core/src/Database/Seeder.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ public function call(array|string $class, bool $silent = false, array $parameter
5757

5858
with(new TwoColumnDetail($this->command->getOutput()))->render(
5959
$name,
60-
"<fg=gray>$runTime ms</> <fg=green;options=bold>DONE</>"
60+
"<fg=gray>{$runTime} ms</> <fg=green;options=bold>DONE</>"
6161
);
6262

6363
$this->command->getOutput()->writeln('');
@@ -111,7 +111,7 @@ protected function resolve(string $class): Seeder
111111

112112
$instance->setContainer($this->container);
113113
} else {
114-
$instance = new $class;
114+
$instance = new $class();
115115
}
116116

117117
if (isset($this->command)) {

0 commit comments

Comments
 (0)