Skip to content

Commit

Permalink
Style fix.
Browse files Browse the repository at this point in the history
  • Loading branch information
bdaler authored and jrushlow committed Jul 12, 2022
1 parent dd1942c commit 525d218
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions src/Maker/MakeSubscriber.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,15 +121,14 @@ public function configureDependencies(DependencyBuilder $dependencies): void

/**
* @param $event
* @return string
*/
private function getEventConstant($event): string
{
$constants = $this->getKernelEventsConstants();

foreach ($constants as $name => $value) {
if ($value === $event) {
return 'KernelEvents::' . $name;
return 'KernelEvents::'.$name;
}
}

Expand All @@ -138,7 +137,6 @@ private function getEventConstant($event): string

/**
* @param $event
* @return bool
*/
private function isNeedImportConstantsClass($event): bool
{
Expand All @@ -153,12 +151,10 @@ private function isNeedImportConstantsClass($event): bool
return false;
}

/**
* @return array
*/
private function getKernelEventsConstants(): array
{
$class = new \ReflectionClass(KernelEvents::class);

return $class->getConstants();
}
}

0 comments on commit 525d218

Please sign in to comment.