From b3e2b8e6a563a18e0317a2bbad06554b019d5f33 Mon Sep 17 00:00:00 2001 From: Arceliar Date: Mon, 26 Nov 2018 19:15:27 -0600 Subject: [PATCH] Update admin.go Replace `nil` with `[]string{}` for `list`'s argument list. --- src/yggdrasil/admin.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/yggdrasil/admin.go b/src/yggdrasil/admin.go index c145a10..86ca657 100644 --- a/src/yggdrasil/admin.go +++ b/src/yggdrasil/admin.go @@ -52,7 +52,7 @@ func (a *admin) addHandler(name string, args []string, handler func(admin_info) func (a *admin) init(c *Core, listenaddr string) { a.core = c a.listenaddr = listenaddr - a.addHandler("list", nil, func(in admin_info) (admin_info, error) { + a.addHandler("list", []string{}, func(in admin_info) (admin_info, error) { handlers := make(map[string]interface{}) for _, handler := range a.handlers { handlers[handler.name] = admin_info{"fields": handler.args}