Skip to content

Commit ce747ad

Browse files
fix(cache): Fix deleted count for cache update
1 parent 4a8a04f commit ce747ad

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

scripts/auto-prepend/refresh-cache.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@
1919

2020
$bouncer = $bounce->init($crowdSecStandaloneBouncerConfig);
2121
$bouncer->refreshBlocklistCache();
22-
echo 'Cache has been refreshed';
22+
echo 'Cache has been refreshed'.PHP_EOL;

src/ApiCache.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -503,6 +503,7 @@ private function removeRemediations(array $decisions): array
503503
'decision' => $decision['id'],
504504
'value' => $decision['value'],
505505
]);
506+
++$count;
506507
}
507508
} elseif (Constants::SCOPE_RANGE === $decision['scope']) {
508509
$range = Subnet::parseString($decision['value']);
@@ -559,6 +560,7 @@ private function removeRemediations(array $decisions): array
559560
'decision' => $decision['id'],
560561
'value' => $decision['value'],
561562
]);
563+
++$count;
562564
}
563565
}
564566
}

0 commit comments

Comments
 (0)