Skip to content

Commit e8b8dc9

Browse files
Use the extraction everywhere
Make sure the Git\ChangedFiles::getChangedFiles method is used.
1 parent 37399ad commit e8b8dc9

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/Runner/Action/Cli/Command/Placeholder/ChangedFiles.php

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,7 @@ class ChangedFiles extends Foundation
3939
*/
4040
public function replacement(array $options): string
4141
{
42-
$factory = new Git\ChangedFiles\Detector\Factory();
43-
$detector = $factory->getDetector($this->io, $this->repository);
44-
45-
$files = $detector->getChangedFiles(['A', 'C', 'M', 'R']);
46-
42+
$files = Git\ChangedFiles::getChangedFiles($this->io, $this->repository, ['A', 'C', 'M', 'R']);
4743
return implode(($options['separated-by'] ?? ' '), FileList::filter($files, $options));
4844
}
4945
}

0 commit comments

Comments
 (0)