From c4afd309b78b5392f427933b7cb423472c4fdbf0 Mon Sep 17 00:00:00 2001 From: Steve Manuel Date: Fri, 30 Dec 2016 02:09:23 -0800 Subject: adding hide to types handler --- system/api/handlers.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'system') diff --git a/system/api/handlers.go b/system/api/handlers.go index ae21500..07201ff 100644 --- a/system/api/handlers.go +++ b/system/api/handlers.go @@ -15,8 +15,10 @@ import ( func typesHandler(res http.ResponseWriter, req *http.Request) { var types = []string{} - for t := range item.Types { - types = append(types, string(t)) + for t, fn := range item.Types { + if !hide(fn(), res) { + types = append(types, t) + } } j, err := toJSON(types) -- cgit v1.2.3