From b7906905c2d72e6117fe8f0703c86b4292d99d6d Mon Sep 17 00:00:00 2001 From: Soam Vasani Date: Sun, 11 Dec 2016 19:59:10 -0800 Subject: [PATCH] Make the internal triggers point to the latest version --- router/httpTriggers.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/router/httpTriggers.go b/router/httpTriggers.go index af8211d1..3e81a9ac 100644 --- a/router/httpTriggers.go +++ b/router/httpTriggers.go @@ -67,15 +67,15 @@ func (ts *HTTPTriggerSet) getRouter() *mux.Router { muxRouter.HandleFunc(trigger.UrlPattern, fh.handler) } - // Internal triggers for each function + // Internal triggers for (the latest version of) each function for _, function := range ts.functions { + m := fission.Metadata{Name: function.Metadata.Name} fh := &functionHandler{ fmap: ts.functionServiceMap, - Function: fission.Metadata{Name: function.Metadata.Name}, + Function: m, poolmgr: ts.poolmgr, } - muxRouter.HandleFunc(fission.UrlForFunction(&function.Metadata), - fh.handler) + muxRouter.HandleFunc(fission.UrlForFunction(&m), fh.handler) } return muxRouter