Skip to content

Commit

Permalink
Changed HTTP to HTTPS redirect status code to 301 (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
sarathyweb committed Feb 19, 2021
1 parent b4d5e90 commit 33ca0bf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion autotls.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,5 @@ func RunWithManager(r http.Handler, m *autocert.Manager) error {
func redirect(w http.ResponseWriter, req *http.Request) {
target := "https://" + req.Host + req.RequestURI

http.Redirect(w, req, target, http.StatusTemporaryRedirect)
http.Redirect(w, req, target, http.StatusMovedPermanently)
}

0 comments on commit 33ca0bf

Please sign in to comment.