зеркало из https://github.com/nextcloud/server.git
fix(apache): Serve `mjs` (module javascript) as static files
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
This commit is contained in:
Родитель
5bf1fc6535
Коммит
e532419b15
|
@ -40,7 +40,7 @@
|
|||
</IfModule>
|
||||
|
||||
# Add cache control for static resources
|
||||
<FilesMatch "\.(css|js|svg|gif|png|jpg|ico|wasm|tflite)$">
|
||||
<FilesMatch "\.(css|js|mjs|svg|gif|png|jpg|ico|wasm|tflite)$">
|
||||
<If "%{QUERY_STRING} =~ /(^|&)v=/">
|
||||
Header set Cache-Control "max-age=15778463, immutable"
|
||||
</If>
|
||||
|
|
|
@ -529,7 +529,7 @@ class Setup {
|
|||
$content .= "\n Options -MultiViews";
|
||||
$content .= "\n RewriteRule ^core/js/oc.js$ index.php [PT,E=PATH_INFO:$1]";
|
||||
$content .= "\n RewriteRule ^core/preview.png$ index.php [PT,E=PATH_INFO:$1]";
|
||||
$content .= "\n RewriteCond %{REQUEST_FILENAME} !\\.(css|js|svg|gif|png|html|ttf|woff2?|ico|jpg|jpeg|map|webm|mp4|mp3|ogg|wav|wasm|tflite)$";
|
||||
$content .= "\n RewriteCond %{REQUEST_FILENAME} !\\.(css|js|mjs|svg|gif|png|html|ttf|woff2?|ico|jpg|jpeg|map|webm|mp4|mp3|ogg|wav|wasm|tflite)$";
|
||||
$content .= "\n RewriteCond %{REQUEST_FILENAME} !/core/ajax/update\\.php";
|
||||
$content .= "\n RewriteCond %{REQUEST_FILENAME} !/core/img/(favicon\\.ico|manifest\\.json)$";
|
||||
$content .= "\n RewriteCond %{REQUEST_FILENAME} !/(cron|public|remote|status)\\.php";
|
||||
|
|
Загрузка…
Ссылка в новой задаче