From 343b72e3f8b427e270bce1154a7949cdc6c03818 Mon Sep 17 00:00:00 2001 From: Nigel Banks Date: Wed, 25 May 2022 07:51:01 -0300 Subject: [PATCH] Count failed checks and report when doing drush batch fixity check. --- src/FixityCheckBatchCheck.php | 3 +++ src/FixityCheckServiceInterface.php | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/FixityCheckBatchCheck.php b/src/FixityCheckBatchCheck.php index e0aa93c..2c1d089 100644 --- a/src/FixityCheckBatchCheck.php +++ b/src/FixityCheckBatchCheck.php @@ -219,6 +219,9 @@ class FixityCheckBatchCheck { if ($result->passed()) { $results['successful']++; } + else { + $results['failed']++; + } } else { // The check was not performed as the time elapsed since the last diff --git a/src/FixityCheckServiceInterface.php b/src/FixityCheckServiceInterface.php index c719418..347da6a 100644 --- a/src/FixityCheckServiceInterface.php +++ b/src/FixityCheckServiceInterface.php @@ -100,7 +100,7 @@ interface FixityCheckServiceInterface { * elapsed since the last check has not exceed the required threshold. * * @return \Drupal\dgi_fixity\Entity\FixityCheckInterface|null - * The resulting fixity_check if successful. + * The resulting fixity_check if performed. * NULL if the check was not performed because the time elapsed since the * last check has not exceed the required threshold. */