Skip to content

Commit 88e5b0d

Browse files
committed
Rename getPackageName to getDefaultPackageName
1 parent ceb43d5 commit 88e5b0d

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/Command/Markdown/GeneratorCommand.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ private function treatFields(InputInterface $input, OutputInterface $output): ar
127127

128128
private function promptName(SymfonyStyle $io): string
129129
{
130-
$name = $io->ask('Project Name', $this->getPackageName());
130+
$name = $io->ask('Project Name', $this->getDefaultPackageName());
131131

132132
if (!$this->isFieldFilled($name)) {
133133
throw new EmptyFieldException('Mention a name for your project 😺');
@@ -276,19 +276,19 @@ private function promptDestinationFile(): Question
276276
);
277277
}
278278

279-
private function getValidPath(?string $path): string
280-
{
281-
return is_string($path) && strlen($path) > 2 ? realpath($path) : DefaultValue::DESTINATION_FILE;
282-
}
283-
284-
private function getPackageName(): string
279+
private function getDefaultPackageName(): string
285280
{
286281
$packageName = explode('/', $this->composerData['name']);
287282
$packageName = str_replace('-', ' ', $packageName[1]);
288283

289284
return ucwords($packageName);
290285
}
291286

287+
private function getValidPath(?string $path): string
288+
{
289+
return is_string($path) && strlen($path) > 2 ? realpath($path) : DefaultValue::DESTINATION_FILE;
290+
}
291+
292292
private function getFilename(): string
293293
{
294294
return sprintf('README-%s.md', date('Y-m-d H:i'));

0 commit comments

Comments
 (0)