Skip to content
This repository has been archived by the owner on Jun 20, 2024. It is now read-only.

Commit

Permalink
Merge pull request #472 from bboreham/master
Browse files Browse the repository at this point in the history
Add peer nickname to JSON status
  • Loading branch information
rade committed Mar 19, 2015
2 parents 6b64516 + 3fbb6ea commit 39e7871
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion router/json.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,11 @@ func (routes *Routes) MarshalJSON() ([]byte, error) {
func (peer *Peer) MarshalJSON() ([]byte, error) {
return json.Marshal(struct {
Name string
Nickname string
UID uint64
Version uint64
Connections []Connection
}{peer.Name.String(), peer.UID, peer.version, peer.Connections()})
}{peer.Name.String(), peer.NickName, peer.UID, peer.version, peer.Connections()})
}

func (conn *RemoteConnection) MarshalJSON() ([]byte, error) {
Expand Down

0 comments on commit 39e7871

Please sign in to comment.