Skip to content

Commit

Permalink
fix: .htaccess customizations get overwritten with updates (#1762)
Browse files Browse the repository at this point in the history
  • Loading branch information
ChaitanyaPTank committed Apr 24, 2024
1 parent e2838f3 commit 4434575
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions public/.htaccess → .htaccess.example
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

<IfModule mod_headers.c>
Header always set Access-Control-Allow-Origin "*"
Header always set Access-Control-Allow-Methods "POST, GET, PUT, OPTIONS, PATCH, DELETE"
Expand Down
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@
"post-install-cmd": [
"@php artisan clear-compiled",
"@php artisan cache:clear",
"@php -r \"if (!file_exists('.env')) copy('.env.example', '.env');\""
"@php -r \"if (!file_exists('.env')) copy('.env.example', '.env');\"",
"@php -r \"if (!file_exists('./public/.htaccess')) copy('.htaccess.example', './public/.htaccess');\""
],
"pre-update-cmd": [
"@php artisan clear-compiled"
Expand Down

0 comments on commit 4434575

Please sign in to comment.