mirror of
https://github.com/caddyserver/caddy.git
synced 2025-01-19 01:05:37 +03:00
rename middleware's name from internal
to inner
The internal package has the special meaning in go (see https://golang.org/s/go14internal). So rename it to `inner`. Signed-off-by: Tw <tw19881113@gmail.com>
This commit is contained in:
parent
00093a2052
commit
90921a9deb
3 changed files with 5 additions and 5 deletions
|
@ -2,7 +2,7 @@ package setup
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/mholt/caddy/middleware"
|
"github.com/mholt/caddy/middleware"
|
||||||
"github.com/mholt/caddy/middleware/internal"
|
"github.com/mholt/caddy/middleware/inner"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Internal configures a new Internal middleware instance.
|
// Internal configures a new Internal middleware instance.
|
||||||
|
@ -13,7 +13,7 @@ func Internal(c *Controller) (middleware.Middleware, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
return func(next middleware.Handler) middleware.Handler {
|
return func(next middleware.Handler) middleware.Handler {
|
||||||
return internal.Internal{Next: next, Paths: paths}
|
return inner.Internal{Next: next, Paths: paths}
|
||||||
}, nil
|
}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
// Package internal provides a simple middleware that (a) prevents access
|
// Package inner provides a simple middleware that (a) prevents access
|
||||||
// to internal locations and (b) allows to return files from internal location
|
// to internal locations and (b) allows to return files from internal location
|
||||||
// by setting a special header, e.g. in a proxy response.
|
// by setting a special header, e.g. in a proxy response.
|
||||||
package internal
|
package inner
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"net/http"
|
"net/http"
|
|
@ -1,4 +1,4 @@
|
||||||
package internal
|
package inner
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
Loading…
Reference in a new issue