reprovide: move core's reprovider into online services
Juan Batiz-Benet committed
Jan 13, 2015 at 22:04 UTC
f068c891476a490ae2b1396d3b5f8a124648c883
1 file changed
+4
-4
core/core.go
+4
-4
@@ -185,10 +185,6 @@ func Standard(cfg *config.Config, online bool) ConfigOption {
185
if err := n.StartOnlineServices(); err != nil {
186
return nil, err // debugerror.Wraps.
187
}
188
-
189
- // Start up reprovider system
190
- n.Reprovider = rp.NewReprovider(n.Routing, n.Blockstore)
191
- go n.Reprovider.Run(ctx)
188
} else {
189
n.Exchange = offline.Exchange(n.Blockstore)
190
}
@@ -253,6 +249,10 @@ func (n *IpfsNode) StartOnlineServices() error {
249
bootstrapPeers = append(bootstrapPeers, p)
250
}
251
go superviseConnections(ctx, n.PeerHost, n.DHT, n.Peerstore, bootstrapPeers)
252
+
253
+ // Start up reprovider system
254
+ n.Reprovider = rp.NewReprovider(n.Routing, n.Blockstore)
255
+ go n.Reprovider.Run(ctx)
256
return nil
257
}
258