mirror of
https://github.com/nspcc-dev/neo-go.git
synced 2024-12-23 23:25:22 +00:00
netmode: make default Magic String() more useful
This commit is contained in:
parent
26f11a52d9
commit
78ff11fe53
1 changed files with 3 additions and 1 deletions
|
@ -1,5 +1,7 @@
|
|||
package netmode
|
||||
|
||||
import "strconv"
|
||||
|
||||
const (
|
||||
// MainNet contains magic code used in the NEO main official network.
|
||||
MainNet Magic = 0x004f454e // 5195086
|
||||
|
@ -26,6 +28,6 @@ func (n Magic) String() string {
|
|||
case UnitTestNet:
|
||||
return "unit_testnet"
|
||||
default:
|
||||
return "net unknown"
|
||||
return "net 0x" + strconv.FormatUint(uint64(n), 16)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue