Skip to content

[ci] adhere to php-cs-fixer standards #1081

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 14, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/EventRegistry.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public function __construct(EventDispatcherInterface $eventDispatcher)

// Loop through the new event classes
foreach (self::$newEventsMap as $eventName => $newEventClass) {
//Check if the new event classes exist, if so replace the old one with the new.
// Check if the new event classes exist, if so replace the old one with the new.
if (isset(self::$eventsMap[$eventName]) && class_exists($newEventClass)) {
self::$eventsMap[$eventName] = $newEventClass;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public function onAuthenticationSuccess(Request $request, TokenInterface $token,
}

// For example:
//return new RedirectResponse($this->urlGenerator->generate('some_route'));
// return new RedirectResponse($this->urlGenerator->generate('some_route'));
throw new \Exception('TODO: provide a valid redirect inside '.__FILE__);
}

Expand Down
4 changes: 2 additions & 2 deletions src/Resources/skeleton/test/KernelTestCase.tpl.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public function testSomething(): void
$kernel = self::bootKernel();

$this->assertSame('test', $kernel->getEnvironment());
//$routerService = <?= $use_legacy_container_property ? 'self::$container' : 'static::getContainer()'; ?>->get('router');
//$myCustomService = <?= $use_legacy_container_property ? 'self::$container' : 'static::getContainer()'; ?>->get(CustomService::class);
// $routerService = <?= $use_legacy_container_property ? 'self::$container' : 'static::getContainer()'; ?>->get('router');
// $myCustomService = <?= $use_legacy_container_property ? 'self::$container' : 'static::getContainer()'; ?>->get(CustomService::class);
}
}
4 changes: 2 additions & 2 deletions src/Util/ClassSourceManipulator.php
Original file line number Diff line number Diff line change
Expand Up @@ -694,7 +694,7 @@ private function addCollectionRelation(BaseCollectionRelation $relation): void
$paramBuilder->setTypeHint($typeHint);
$adderNodeBuilder->addParam($paramBuilder->getNode());

//if (!$this->avatars->contains($avatar))
// if (!$this->avatars->contains($avatar))
$containsMethodCallNode = new Node\Expr\MethodCall(
new Node\Expr\PropertyFetch(new Node\Expr\Variable('this'), $relation->getPropertyName()),
'contains',
Expand Down Expand Up @@ -749,7 +749,7 @@ private function addCollectionRelation(BaseCollectionRelation $relation): void
// $this->avatars->removeElement($avatar);
$removerNodeBuilder->addStmt(BuilderHelpers::normalizeStmt($removeElementCall));
} else {
//if ($this->avatars->removeElement($avatar))
// if ($this->avatars->removeElement($avatar))
$ifRemoveElementStmt = new Node\Stmt\If_($removeElementCall);
$removerNodeBuilder->addStmt($ifRemoveElementStmt);
if ($relation instanceof RelationOneToMany) {
Expand Down
2 changes: 1 addition & 1 deletion src/Util/YamlSourceManipulator.php
Original file line number Diff line number Diff line change
Expand Up @@ -835,7 +835,7 @@ private function findEndPositionOfValue($value, $offset = null)
return $endKeyPosition;
}

if (is_scalar($value) || null === $value) {
if (\is_scalar($value) || null === $value) {
$offset = null === $offset ? $this->currentPosition : $offset;

if (\is_bool($value)) {
Expand Down
2 changes: 0 additions & 2 deletions tests/Util/ClassSourceManipulatorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -648,7 +648,6 @@ public function getAddOneToOneRelationTests(): \Generator
(new RelationOneToOne())
->setPropertyName('userProfile')
->setTargetClassName('App\Entity\UserProfile')
//->setTargetPropertyName('user')
->setIsNullable(true)
->setIsOwning(true)
->setMapInverseRelation(false),
Expand All @@ -660,7 +659,6 @@ public function getAddOneToOneRelationTests(): \Generator
(new RelationOneToOne())
->setPropertyName('userProfile')
->setTargetClassName('App\Entity\UserProfile')
//->setTargetPropertyName('user')
->setIsNullable(false)
->setIsOwning(true)
->setMapInverseRelation(false),
Expand Down
2 changes: 1 addition & 1 deletion tests/Util/YamlSourceManipulatorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public function testSetData(string $startingSource, array $newData, string $expe

$logger = $this->createLogger();
// uncomment to enhance debugging
//$manipulator->setLogger($logger);
// $manipulator->setLogger($logger);

$manipulator->setData($newData);

Expand Down