Skip to content

Commit e763273

Browse files
committed
Apply allowed query string params
1 parent 79d31e0 commit e763273

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,9 @@
22

33
## 5.11.5 - Unreleased
44

5-
- URIs with encoded period segments are no longer cached.
5+
- URIs with period-only segments are no longer cached.
66
- Fixed a bug in which “cached by Blitz” comments were not being output.
7+
- Fixed a bug in which allowed query string params were not being applied when query string caching was set to `Do not cache URLs with query strings` ([#815](https://github.com/putyourlightson/craft-blitz/issues/815)).
78

89
## 5.11.4 - 2025-06-03
910

src/services/CacheRequestService.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -472,9 +472,7 @@ public function getRequestedCacheableSiteUri(): ?SiteUriModel
472472
}
473473

474474
$allowedQueryString = '';
475-
if (Blitz::$plugin->settings->queryStringCaching === SettingsModel::QUERY_STRINGS_DO_NOT_CACHE_URLS) {
476-
$allowedQueryString = $queryString;
477-
} elseif (Blitz::$plugin->settings->queryStringCaching === SettingsModel::QUERY_STRINGS_CACHE_URLS_AS_UNIQUE_PAGES) {
475+
if (Blitz::$plugin->settings->queryStringCaching !== SettingsModel::QUERY_STRINGS_CACHE_URLS_AS_SAME_PAGE) {
478476
$allowedQueryString = $this->getAllowedQueryString($site->id, '?' . $queryString);
479477
}
480478
if ($allowedQueryString) {

0 commit comments

Comments
 (0)