Skip to content

Commit

Permalink
Revert deleting expired URIs immediately
Browse files Browse the repository at this point in the history
  • Loading branch information
bencroker committed Feb 24, 2024
1 parent a664f99 commit aede7ea
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
### Changed

- Tracked element queries that have invalid params or that cannot be executed are now deleted when refreshing the cache.
- Reverted deleting expired URIs from the database immediately when refreshing expired cache, as it can cause cached pages not to be refreshed ([#624](https://github.com/putyourlightson/craft-blitz/issues/624)).


## 4.11.2 - 2024-02-19

Expand Down
3 changes: 0 additions & 3 deletions src/services/RefreshCacheService.php
Original file line number Diff line number Diff line change
Expand Up @@ -476,9 +476,6 @@ public function refreshExpiredCache(): void
$cacheIds = Blitz::$plugin->expireCache->getExpiredCacheIds();
$this->addCacheIds($cacheIds);

// Delete the cache records now, as they may not be deleted later.
CacheRecord::deleteAll(['id' => $cacheIds]);

// Check for expired elements to invalidate
/** @var ElementExpiryDateRecord[] $elementExpiryDates */
$elementExpiryDates = ElementExpiryDateRecord::find()
Expand Down

0 comments on commit aede7ea

Please sign in to comment.