From 075aba63ff98f6f16383f27895856da1569761c4 Mon Sep 17 00:00:00 2001 From: Steve Manuel Date: Tue, 15 Aug 2017 13:39:00 -0600 Subject: update Omittable, Pushable, interface to take res, req pair like Hooks, update implementations & hydrate items --- system/api/search.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'system/api/search.go') diff --git a/system/api/search.go b/system/api/search.go index 9c7f0ae..b77de68 100644 --- a/system/api/search.go +++ b/system/api/search.go @@ -26,7 +26,7 @@ func searchContentHandler(res http.ResponseWriter, req *http.Request) { return } - if hide(it(), res, req) { + if hide(res, req, it()) { return } @@ -64,7 +64,7 @@ func searchContentHandler(res http.ResponseWriter, req *http.Request) { // if we have matches, push the first as its matched by relevance if len(bb) > 0 { - push(res, req, it, bb[0]) + push(res, req, it(), bb[0]) } var result = []json.RawMessage{} @@ -78,7 +78,7 @@ func searchContentHandler(res http.ResponseWriter, req *http.Request) { return } - j, err = omit(it(), j) + j, err = omit(res, req, it(), j) if err != nil { res.WriteHeader(http.StatusInternalServerError) return -- cgit v1.2.3