Skip to content

Commit 82d6630

Browse files
authored
refactor: Fix typo (#976)
1 parent 6c5b8ee commit 82d6630

File tree

4 files changed

+16
-16
lines changed

4 files changed

+16
-16
lines changed

src/Console/Command/InspectCommand.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,9 @@ public function execute(IO $io): int
120120
$symbolsRegistry = new SymbolsRegistry();
121121
$fileContents = $config->getFilesWithContents()[$filePath][1];
122122

123-
$scoppedContents = $this->scopeFile($config, $symbolsRegistry, $filePath, $fileContents);
123+
$scopedContents = $this->scopeFile($config, $symbolsRegistry, $filePath, $fileContents);
124124

125-
$this->printScoppedContents($io, $scoppedContents, $symbolsRegistry);
125+
$this->printScopedContents($io, $scopedContents, $symbolsRegistry);
126126

127127
return ExitCode::SUCCESS;
128128
}
@@ -206,19 +206,19 @@ private function scopeFile(
206206
);
207207
}
208208

209-
private function printScoppedContents(
209+
private function printScopedContents(
210210
IO $io,
211-
string $scoppedContents,
211+
string $scopedContents,
212212
SymbolsRegistry $symbolsRegistry,
213213
): void {
214214
if ($io->isQuiet()) {
215-
$io->writeln($scoppedContents, OutputInterface::VERBOSITY_QUIET);
215+
$io->writeln($scopedContents, OutputInterface::VERBOSITY_QUIET);
216216
} else {
217217
$io->writeln([
218-
'Scopped contents:',
218+
'Scoped contents:',
219219
'',
220220
'<comment>"""</comment>',
221-
$scoppedContents,
221+
$scopedContents,
222222
'<comment>"""</comment>',
223223
]);
224224

src/Console/ConsoleScoper.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ private function scopeFile(
306306
$inputFilePath = $file->inputFilePath;
307307

308308
try {
309-
$scoppedContent = $scoper->scope(
309+
$scopedContent = $scoper->scope(
310310
$inputFilePath,
311311
$file->inputContents,
312312
);
@@ -316,7 +316,7 @@ private function scopeFile(
316316
$logger->outputWarnOfFailure($inputFilePath, $parsingException);
317317

318318
// Fallback on unchanged content
319-
$scoppedContent = $file->inputContents;
319+
$scopedContent = $file->inputContents;
320320
} catch (Throwable $throwable) {
321321
$exception = ParsingException::forFile(
322322
$inputFilePath,
@@ -330,11 +330,11 @@ private function scopeFile(
330330
$logger->outputWarnOfFailure($inputFilePath, $exception);
331331

332332
// Fallback on unchanged content
333-
$scoppedContent = $file->inputContents;
333+
$scopedContent = $file->inputContents;
334334
}
335335

336336
$this->dumpFileWithPermissions(
337-
$file->withScoppedContent($scoppedContent),
337+
$file->withScopedContent($scopedContent),
338338
);
339339

340340
if ($successfullyScoped) {

src/Console/File.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ public function __construct(
2626
) {
2727
}
2828

29-
public function withScoppedContent(string $scoppedContent): self
29+
public function withScopedContent(string $scopedContent): self
3030
{
3131
return new self(
3232
$this->inputFilePath,
33-
$scoppedContent,
33+
$scopedContent,
3434
$this->outputFilePath,
3535
);
3636
}

tests/Console/Command/AddInspectCommandIntegrationTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ protected function setUp(): void
5050
$this->appTester = AppTester::fromConsoleApp($application);
5151
}
5252

53-
public function test_it_shows_the_scopped_content_of_the_file_given(): void
53+
public function test_it_shows_the_scoped_content_of_the_file_given(): void
5454
{
5555
$input = [
5656
'inspect',
@@ -65,7 +65,7 @@ public function test_it_shows_the_scopped_content_of_the_file_given(): void
6565
OutputAssertions::assertSameOutput(
6666
<<<'PHP'
6767
68-
Scopped contents:
68+
Scoped contents:
6969
7070
"""
7171
<?php
@@ -93,7 +93,7 @@ public function test_it_shows_the_scopped_content_of_the_file_given(): void
9393
);
9494
}
9595

96-
public function test_it_shows_the_raw_scopped_content_of_the_file_given_in_quiet_mode(): void
96+
public function test_it_shows_the_raw_scoped_content_of_the_file_given_in_quiet_mode(): void
9797
{
9898
$input = [
9999
'inspect',

0 commit comments

Comments
 (0)