From abb10e9cbfe5b28b693e3a138e54be495538ed31 Mon Sep 17 00:00:00 2001 From: ZaniaDevelopper Date: Fri, 23 Feb 2018 09:24:35 +0300 Subject: [PATCH] Add a missing call for `fallbackHandler` Former-commit-id: a1ce94b39d326657cdbce34276477c34752f0000 --- _examples/routing/fallback-handlers/main.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/_examples/routing/fallback-handlers/main.go b/_examples/routing/fallback-handlers/main.go index 66308ae4..aa3c871b 100644 --- a/_examples/routing/fallback-handlers/main.go +++ b/_examples/routing/fallback-handlers/main.go @@ -7,6 +7,9 @@ import ( func main() { app := iris.New() + // add a fallback handler to process requests that would not be declared in the router. + app.Fallback(fallbackHandler) + // this works as expected now, // will handle *all* expect DELETE requests, even if there is no routes app.Get("/action/{p}", h)