@cryptotaxi247 / kubo / commits / fbc495db4

Fix "PNetFingerpint" field typo of core.IpfsNode

License: MIT Signed-off-by: Jason Chang <ridewindx@163.com>

RideWindX committed Mar 1, 2018 at 18:36 UTC fbc495db4c97f6b2b8ec96e4a5ebaacfa1239dd0
2 files changed +7 -7
cmd/ipfs/daemon.go
+2 -2
@@ -319,9 +319,9 @@ func daemonFunc(req *cmds.Request, re cmds.ResponseEmitter, env cmds.Environment
319 }
320 node.SetLocal(false)
321
322 - if node.PNetFingerpint != nil {
322 + if node.PNetFingerprint != nil {
323 fmt.Println("Swarm is limited to private network of peers with the swarm key")
324 - fmt.Printf("Swarm key fingerprint: %x\n", node.PNetFingerpint)
324 + fmt.Printf("Swarm key fingerprint: %x\n", node.PNetFingerprint)
325 }
326
327 printSwarmAddrs(node)
core/core.go
+5 -5
@@ -106,10 +106,10 @@ type IpfsNode struct {
106 Repo repo.Repo
107
108 // Local node
109 - Pinning pin.Pinner // the pinning manager
110 - Mounts Mounts // current mount state, if any.
111 - PrivateKey ic.PrivKey // the local node's private Key
112 - PNetFingerpint []byte // fingerprint of private network
109 + Pinning pin.Pinner // the pinning manager
110 + Mounts Mounts // current mount state, if any.
111 + PrivateKey ic.PrivKey // the local node's private Key
112 + PNetFingerprint []byte // fingerprint of private network
113
114 // Services
115 Peerstore pstore.Peerstore // storage for other Peer instances
@@ -195,7 +195,7 @@ func (n *IpfsNode) startOnlineServices(ctx context.Context, routingOption Routin
195 if err != nil {
196 return err
197 }
198 - n.PNetFingerpint = protec.Fingerprint()
198 + n.PNetFingerprint = protec.Fingerprint()
199 go func() {
200 t := time.NewTicker(30 * time.Second)
201 <-t.C // swallow one tick