Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[stable25] Fix Cache-Control header of non-versioned assets #37249

Merged
merged 1 commit into from
Mar 16, 2023

Conversation

backportbot-nextcloud[bot]
Copy link

backport of #37010

Non-cache-busted assets such as /dist/core-main.js also matched the
regex meant for cache-busted assets (note the ? at the end of the
regex).
The FilesMatch directive for cache-busted assets coming after the
non-cache-busted version all assets actually got the immutable flag
in their Cache-Control header. This caused client-side errors on
updates.

Query strings are not actually passed to FilesMatch directives so we
need another way to tell cache-busted/versionned assets apart from
non-versioned assets, here using If/Else directives.

Signed-off-by: Nicolas Guichard <nicolas@guichard.eu>
@backportbot-nextcloud backportbot-nextcloud bot added this to the Nextcloud 25.0.5 milestone Mar 15, 2023
@blizzz blizzz mentioned this pull request Mar 16, 2023
@blizzz blizzz added the 3. to review Waiting for reviews label Mar 16, 2023
@MichaIng MichaIng requested a review from solracsf March 16, 2023 14:49
@MichaIng MichaIng enabled auto-merge March 16, 2023 14:50
@blizzz blizzz disabled auto-merge March 16, 2023 16:11
@blizzz blizzz merged commit fd7d86a into stable25 Mar 16, 2023
@blizzz blizzz deleted the backport/37010/stable25 branch March 16, 2023 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants