Skip to content

Commit

Permalink
Fix marking all pages as expired
Browse files Browse the repository at this point in the history
  • Loading branch information
bencroker committed Dec 21, 2023
1 parent c915a64 commit 714cc8a
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Release Notes for Blitz

## 4.9.5 - Unreleased

### Fixed

- Fixed a bug in which all cached pages were being marked as expired when no cacheable site URIs were refreshed ([#598](https://github.com/putyourlightson/craft-blitz/issues/598)).

## 4.9.4 - 2023-12-19

### Changed
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "putyourlightson/craft-blitz",
"description": "Intelligent static page caching for creating lightning-fast sites.",
"version": "4.9.4",
"version": "4.9.5",
"type": "craft-plugin",
"homepage": "https://putyourlightson.com/plugins/blitz",
"license": "proprietary",
Expand Down
5 changes: 4 additions & 1 deletion src/helpers/SiteUriHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -318,11 +318,14 @@ public static function getAssetSiteUris(array $elementIds): array
/**
* Returns cache IDs from the given site URIs.
*
* @param SiteUriModel[] $siteUris
* @return int[]
*/
public static function getCacheIdsFromSiteUris(array $siteUris): array
{
if (empty($siteUris)) {
return [];
}

$condition = ['or'];

foreach ($siteUris as $siteUri) {
Expand Down

0 comments on commit 714cc8a

Please sign in to comment.