Module.New() does not need to return an error

This commit is contained in:
Matthew Holt
2019-05-21 14:22:21 -06:00
parent 67d32e6779
commit 2fd98cb040
19 changed files with 29 additions and 36 deletions

View File

@ -9,12 +9,12 @@ import (
func init() {
caddy2.RegisterModule(caddy2.Module{
Name: "http.middleware.table",
New: func() (interface{}, error) { return new(tableMiddleware), nil },
New: func() interface{} { return new(tableMiddleware) },
})
caddy2.RegisterModule(caddy2.Module{
Name: "http.matchers.table",
New: func() (interface{}, error) { return new(tableMatcher), nil },
New: func() interface{} { return new(tableMatcher) },
})
}