From aa5daed3cb0fe9a98f6ab0bba1a50eddfc6cc572 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Magiera?= Date: Fri, 26 Oct 2018 02:28:28 +0200 Subject: [PATCH] NoFetch gateway option MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit License: MIT Signed-off-by: Ɓukasz Magiera --- core/corehttp/gateway.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/corehttp/gateway.go b/core/corehttp/gateway.go index 52560750a..de909a0ef 100644 --- a/core/corehttp/gateway.go +++ b/core/corehttp/gateway.go @@ -2,6 +2,7 @@ package corehttp import ( "fmt" + "github.com/ipfs/go-ipfs/core/coreapi/interface/options" "net" "net/http" @@ -25,7 +26,7 @@ func GatewayOption(writable bool, paths ...string) ServeOption { return nil, err } - api, err := coreapi.NewCoreAPI(n) + api, err := coreapi.NewCoreAPI(n, options.Api.Offline(cfg.Gateway.NoFetch)) if err != nil { return nil, err }