diff --git a/gateway/hostname.go b/gateway/hostname.go index 65986e0e4..7c72787b6 100644 --- a/gateway/hostname.go +++ b/gateway/hostname.go @@ -83,7 +83,7 @@ func WithHostname(c Config, api IPFSBackend, next http.Handler) http.HandlerFunc if !gw.NoDNSLink && hasDNSLinkRecord(r.Context(), api, host) { // rewrite path and handle as DNSLink r.URL.Path = "/ipns/" + stripPort(host) + r.URL.Path - next.ServeHTTP(w, withSubdomainContext(r, host)) + next.ServeHTTP(w, withDNSLinkContext(r, host)) return }