Skip to content

Commit

Permalink
chore: deprecate Gateway.PathPrefixes
Browse files Browse the repository at this point in the history
Context:
ipfs/kubo#7702 (comment)


This commit was moved from ipfs/kubo@2f105f7
  • Loading branch information
lidel committed Mar 30, 2021
1 parent 774ccd7 commit 8736ffc
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions gateway/core/corehttp/gateway_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ func (i *gatewayHandler) getOrHeadHandler(w http.ResponseWriter, r *http.Request
// If the gateway is behind a reverse proxy and mounted at a sub-path,
// the prefix header can be set to signal this sub-path.
// It will be prepended to links in directory listings and the index.html redirect.
// TODO: this feature is deprecated and will be removed (https://github.com/ipfs/go-ipfs/issues/7702)
prefix := ""
if prfx := r.Header.Get("X-Ipfs-Gateway-Prefix"); len(prfx) > 0 {
for _, p := range i.config.PathPrefixes {
Expand Down

0 comments on commit 8736ffc

Please sign in to comment.