mirror of
https://github.com/cwinfo/yggdrasil-go.git
synced 2024-12-23 12:15:39 +00:00
Update admin.go
This commit is contained in:
parent
cdedd304af
commit
3a1b67da8c
@ -58,7 +58,7 @@ func (a *admin) init(c *Core, listenaddr string) {
|
||||
a.addHandler("getSessions", nil, func(out *[]byte, _ ...string) {
|
||||
*out = []byte(a.printInfos(a.getData_getSessions()))
|
||||
})
|
||||
a.addHandler("addPeer", []string{"<port>"}, func(out *[]byte, saddr ...string) {
|
||||
a.addHandler("addPeer", []string{"<proto://address:port>"}, func(out *[]byte, saddr ...string) {
|
||||
if a.addPeer(saddr[0]) == nil {
|
||||
*out = []byte("Adding peer: " + saddr[0] + "\n")
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user