File tree 1 file changed +2
-10
lines changed
1 file changed +2
-10
lines changed Original file line number Diff line number Diff line change 17
17
package eth
18
18
19
19
import (
20
- "math/big"
21
-
22
20
"github.com/ethereum/go-ethereum/eth/protocols/eth"
23
21
"github.com/ethereum/go-ethereum/eth/protocols/snap"
24
22
)
25
23
26
24
// ethPeerInfo represents a short summary of the `eth` sub-protocol metadata known
27
25
// about a connected peer.
28
26
type ethPeerInfo struct {
29
- Version uint `json:"version"` // Ethereum protocol version negotiated
30
- Difficulty * big.Int `json:"difficulty"` // Total difficulty of the peer's blockchain
31
- Head string `json:"head"` // Hex hash of the peer's best owned block
27
+ Version uint `json:"version"` // Ethereum protocol version negotiated
32
28
}
33
29
34
30
// ethPeer is a wrapper around eth.Peer to maintain a few extra metadata.
@@ -39,12 +35,8 @@ type ethPeer struct {
39
35
40
36
// info gathers and returns some `eth` protocol metadata known about a peer.
41
37
func (p * ethPeer ) info () * ethPeerInfo {
42
- hash , td := p .Head ()
43
-
44
38
return & ethPeerInfo {
45
- Version : p .Version (),
46
- Difficulty : td ,
47
- Head : hash .Hex (),
39
+ Version : p .Version (),
48
40
}
49
41
}
50
42
You can’t perform that action at this time.
0 commit comments