Skip to content

Commit 07b34d4

Browse files
dermatzCopilot
andauthored
Update src/Service/NodePackageManager.php
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 8e0a4a9 commit 07b34d4

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

src/Service/NodePackageManager.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,10 @@ private function diagnoseAndReportNpmFailure(string $path, SymfonyStyle $io, \Ex
169169
if (!$this->isPackageJsonValid($path)) {
170170
$io->error('package.json is missing or contains invalid JSON.');
171171
$io->writeln('<fg=yellow>Fix:</>');
172-
$io->writeln(' Verify package.json exists at: ' . $path . '/package.json');
172+
$sanitizedPath = preg_replace('/[[:cntrl:]]/', '', $path);
173+
$io->writeln(
174+
' Verify package.json exists at: ' . $sanitizedPath . '/package.json'
175+
);
173176
return;
174177
}
175178

0 commit comments

Comments
 (0)