1
0
mirror of https://github.com/ipfs/kubo.git synced 2025-06-27 16:07:42 +08:00

fix node context (tests pass)

This commit is contained in:
Juan Batiz-Benet
2014-11-17 22:46:50 -08:00
parent 088016c850
commit d93e49e06e

View File

@ -111,7 +111,7 @@ func NewIpfsNode(cfg *config.Config, online bool) (n *IpfsNode, err error) {
onlineMode: online,
Config: cfg,
}
n.ContextCloser = ctxc.NewContextCloser(context.TODO(), n.teardown)
n.ContextCloser = ctxc.NewContextCloser(ctx, n.teardown)
// setup datastore.
if n.Datastore, err = makeDatastore(cfg.Datastore); err != nil {