Fix exact match of .js files. Was also matching .json before.

This commit is contained in:
Stephan Oeste 2023-05-25 16:50:56 +02:00
parent 34500f7d47
commit ad4c7d7c0b
No known key found for this signature in database
GPG Key ID: 3152347D07DA627C

View File

@ -59,7 +59,7 @@ location = / {
}
# cache /<lang>/main.f40e91d908a068a2.js forever since they never change
location ~ ^/([a-z][a-z])/(.+\..+\.(js|css)) {
location ~ ^/([a-z][a-z])/(.+\..+\.(js|css))$ {
try_files $uri =404;
expires 1y;
}
@ -82,7 +82,7 @@ location /resources {
expires 1w;
}
# cache /main.f40e91d908a068a2.js forever since they never change
location ~* ^/.+\..+\.(js|css) {
location ~* ^/.+\..+\.(js|css)$ {
try_files /$lang/$uri /en-US/$uri =404;
expires 1y;
}