mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 02:12:23 +00:00
rm redundancy
This commit is contained in:
parent
0404cbc062
commit
278086e5fd
1 changed files with 2 additions and 3 deletions
|
|
@ -46,9 +46,8 @@ func handleRequest(conn net.Conn) {
|
||||||
if err == nil {
|
if err == nil {
|
||||||
fmt.Println("Message is ", string(buf[:msg]))
|
fmt.Println("Message is ", string(buf[:msg]))
|
||||||
var dat map[string]interface{}
|
var dat map[string]interface{}
|
||||||
byt := []byte(string(buf[:msg]))
|
|
||||||
|
if err := json.Unmarshal(buf[:msg], &dat); err != nil {
|
||||||
if err := json.Unmarshal(byt, &dat); err != nil {
|
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
fmt.Println(dat["address"])
|
fmt.Println(dat["address"])
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue