From 99430ca66903500ca088e67ea1a64efa84b82bd3 Mon Sep 17 00:00:00 2001 From: Jordi Boggiano Date: Wed, 11 Dec 2024 11:29:49 +0100 Subject: [PATCH] Avoid returning failing status code if the composer audit fails in diagnose command, refs #12196 --- src/Composer/Command/DiagnoseCommand.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Composer/Command/DiagnoseCommand.php b/src/Composer/Command/DiagnoseCommand.php index 7dade55ef..b209679f5 100644 --- a/src/Composer/Command/DiagnoseCommand.php +++ b/src/Composer/Command/DiagnoseCommand.php @@ -595,11 +595,11 @@ EOT $io = new BufferIO(); $result = $auditor->audit($io, $repoSet, $packages, Auditor::FORMAT_TABLE, true, [], Auditor::ABANDONED_IGNORE); } catch (\Throwable $e) { - return 'Failed performing audit: '.$e->getMessage().''; + return 'Failed performing audit: '.$e->getMessage().''; } if ($result > 0) { - return 'Audit found some issues:' . PHP_EOL . $io->getOutput(); + return 'Audit found some issues:' . PHP_EOL . $io->getOutput(); } return true;