Skip to content

Commit

Permalink
Fix apache and simulated mod_rewrite inconsistencies
Browse files Browse the repository at this point in the history
  • Loading branch information
giuscris committed Oct 6, 2024
1 parent 272e428 commit f71bf3d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .htaccess
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ AddDefaultCharset utf-8
RewriteRule ^(panel|backup|bin|cache|formwork|site|vendor)/.* index.php [L,NC]

## Prevent access to specific files
RewriteRule ^(.*)\.(md|yml|json|neon)/?$ index.php [L,NC]
RewriteRule ^(.*)\.(md|yml|yaml|json|neon)/?$ index.php [L,NC]
RewriteRule ^(\.(.*)|LICENSE|composer\.lock)/?$ index.php [L,NC]
</IfModule>

Expand Down
2 changes: 1 addition & 1 deletion formwork/server.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
return false;

case preg_match('~^/(panel|backup|bin|cache|formwork|site|vendor)/.*~i', $path):
case preg_match('~^/(.*)\.(md|yaml|json|neon)/?$~i', $path):
case preg_match('~^/(.*)\.(md|yml|yaml|json|neon)/?$~i', $path):
case preg_match('~^/(\.(.*)|LICENSE|composer\.lock)/?$~i', $path):
break;

Expand Down

0 comments on commit f71bf3d

Please sign in to comment.