Skip to content

Commit

Permalink
api error fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ironicbadger committed Dec 26, 2024
1 parent 235533c commit a10bf18
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions nginx/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,11 @@ server {
index index.html index.htm;
}

# Option 1: More detailed analytics handling
location /api/ {
# Log analytics attempts without errors
access_log /var/log/nginx/analytics.log;
error_log /dev/null;
return 204;
# Add this block to handle Material for MkDocs API events
location /api/event {
access_log off; # Don't log these requests
error_log /dev/null; # Don't log errors for these requests
return 204; # Return "No Content" status
}

error_page 404 /404.html;
Expand Down

0 comments on commit a10bf18

Please sign in to comment.