Skip to content

Commit 988f765

Browse files
committed
php-cs-fixer it up
1 parent b7fd3e3 commit 988f765

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

src/Maker/MakeCrud.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ public function generate(InputInterface $input, ConsoleStyle $io, Generator $gen
148148
} while (class_exists($formClassDetails->getFullName()));
149149

150150
$controllerClassData = ClassData::create(
151-
class: sprintf('Controller\%s', $this->controllerClassName),
151+
class: \sprintf('Controller\%s', $this->controllerClassName),
152152
suffix: 'Controller',
153153
extendsClass: AbstractController::class,
154154
useStatements: [
@@ -248,7 +248,7 @@ class: sprintf('Controller\%s', $this->controllerClassName),
248248

249249
if ($this->shouldGenerateTests()) {
250250
$testClassData = ClassData::create(
251-
class: sprintf('Tests\Controller\%s', $entityClassDetails->getRelativeNameWithoutSuffix()),
251+
class: \sprintf('Tests\Controller\%s', $entityClassDetails->getRelativeNameWithoutSuffix()),
252252
suffix: 'ControllerTest',
253253
extendsClass: WebTestCase::class,
254254
useStatements: [

src/Maker/MakeVoter.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ public function configureCommand(Command $command, InputConfiguration $inputConf
5050
public function generate(InputInterface $input, ConsoleStyle $io, Generator $generator): void
5151
{
5252
$voterClassData = ClassData::create(
53-
class: sprintf('Security\Voter\%s', $input->getArgument('name')),
53+
class: \sprintf('Security\Voter\%s', $input->getArgument('name')),
5454
suffix: 'Voter',
5555
extendsClass: Voter::class,
5656
useStatements: [

src/Util/ClassSource/Model/ClassData.php

+5-5
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public static function create(string $class, ?string $suffix = null, ?string $ex
3737
$className = Str::getShortClassName($class);
3838

3939
if (null !== $suffix && !str_ends_with($className, $suffix)) {
40-
$className = Str::asClassName(sprintf('%s%s', $className, $suffix));
40+
$className = Str::asClassName(\sprintf('%s%s', $className, $suffix));
4141
}
4242

4343
$useStatements = new UseStatementGenerator($useStatements);
@@ -66,12 +66,12 @@ public function getNamespace(): string
6666
return $this->rootNamespace;
6767
}
6868

69-
return sprintf('%s\%s', $this->rootNamespace, $this->namespace);
69+
return \sprintf('%s\%s', $this->rootNamespace, $this->namespace);
7070
}
7171

7272
public function getFullClassName(): string
7373
{
74-
return sprintf('%s\%s', $this->getNamespace(), $this->className);
74+
return \sprintf('%s\%s', $this->getNamespace(), $this->className);
7575
}
7676

7777
public function setRootNamespace(string $rootNamespace): self
@@ -86,10 +86,10 @@ public function getClassDeclaration(): string
8686
$extendsDeclaration = '';
8787

8888
if (null !== $this->extends) {
89-
$extendsDeclaration = sprintf(' extends %s', $this->extends);
89+
$extendsDeclaration = \sprintf(' extends %s', $this->extends);
9090
}
9191

92-
return sprintf('%sclass %s%s',
92+
return \sprintf('%sclass %s%s',
9393
$this->isFinal ? 'final ' : '',
9494
$this->className,
9595
$extendsDeclaration,

tests/Util/TemplateComponentGeneratorTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ public function testGetFinalClassDeclaration(bool $finalClass, bool $finalEntity
102102

103103
$generator->configureClass($classData);
104104

105-
self::assertSame(sprintf('%sclass MakerBundle', $expectedResult), $classData->getClassDeclaration());
105+
self::assertSame(\sprintf('%sclass MakerBundle', $expectedResult), $classData->getClassDeclaration());
106106
}
107107

108108
public function finalClassDataProvider(): \Generator

0 commit comments

Comments
 (0)