diff --git a/core/commands2/id.go b/core/commands2/id.go index 8d9c773392f..ba8f9c5d0d9 100644 --- a/core/commands2/id.go +++ b/core/commands2/id.go @@ -52,10 +52,7 @@ if no peer is specified, prints out local peers info. return printPeer(node.Identity) } - pid, ok := req.Arguments()[0].(string) - if !ok { - return nil, cmds.ClientError("Improperly formatted peer id") - } + pid := req.Arguments()[0] id := peer.ID(b58.Decode(pid)) if len(id) == 0 {