Skip to content

Commit

Permalink
Fix HEAD method for robots.txt (go-gitea#30603)
Browse files Browse the repository at this point in the history
  • Loading branch information
wxiaoguang authored and GiteaBot committed Apr 19, 2024
1 parent 199397a commit ed9a8d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion routers/web/web.go
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ func Routes() *web.Route {
routes.Get("/metrics", append(mid, Metrics)...)
}

routes.Get("/robots.txt", append(mid, misc.RobotsTxt)...)
routes.Methods("GET,HEAD", "/robots.txt", append(mid, misc.RobotsTxt)...)
routes.Get("/ssh_info", misc.SSHInfo)
routes.Get("/api/healthz", healthcheck.Check)

Expand Down

0 comments on commit ed9a8d8

Please sign in to comment.