+2
-2
appview/state/git_http.go
+2
-2
appview/state/git_http.go
···
15
repo := chi.URLParam(r, "repo")
16
17
// TODO: make this https for production!
18
-
targetURL := fmt.Sprintf("http://%s/%s/%s/info/refs?%s", knot, user.DID, repo, r.URL.RawQuery)
19
resp, err := http.Get(targetURL)
20
if err != nil {
21
http.Error(w, err.Error(), http.StatusInternalServerError)
···
48
knot := r.Context().Value("knot").(string)
49
repo := chi.URLParam(r, "repo")
50
// TODO: make this https for production!
51
-
targetURL := fmt.Sprintf("http://%s/%s/%s/git-upload-pack?%s", knot, user.DID, repo, r.URL.RawQuery)
52
client := &http.Client{}
53
54
// Create new request
···
15
repo := chi.URLParam(r, "repo")
16
17
// TODO: make this https for production!
18
+
targetURL := fmt.Sprintf("https://%s/%s/%s/info/refs?%s", knot, user.DID, repo, r.URL.RawQuery)
19
resp, err := http.Get(targetURL)
20
if err != nil {
21
http.Error(w, err.Error(), http.StatusInternalServerError)
···
48
knot := r.Context().Value("knot").(string)
49
repo := chi.URLParam(r, "repo")
50
// TODO: make this https for production!
51
+
targetURL := fmt.Sprintf("https://%s/%s/%s/git-upload-pack?%s", knot, user.DID, repo, r.URL.RawQuery)
52
client := &http.Client{}
53
54
// Create new request