prepare release

pull/2325/head
René Werner 2023-02-03 13:59:47 +01:00
parent 675f5181ce
commit 028d821bea
3 changed files with 8 additions and 5 deletions

View File

@ -86,6 +86,9 @@ linters-settings:
disabled: true
- name: cyclomatic
disabled: true
- name: early-return
severity: warning
disabled: true
- name: exported
disabled: true
- name: file-header

View File

@ -19,23 +19,23 @@ type Config struct {
// File holds the path to an actual favicon that will be cached
//
// Optional. Default: ""
File string
File string `json:"file"`
// URL for favicon handler
//
// Optional. Default: "/favicon.ico"
URL string
URL string `json:"url"`
// FileSystem is an optional alternate filesystem to search for the favicon in.
// An example of this could be an embedded or network filesystem
//
// Optional. Default: nil
FileSystem http.FileSystem
FileSystem http.FileSystem `json:"-"`
// CacheControl defines how the Cache-Control header in the response should be set
//
// Optional. Default: "public, max-age=31536000"
CacheControl string
CacheControl string `json:"cache_control"`
}
// ConfigDefault is the default config

View File

@ -572,7 +572,7 @@ func findGreedyParamLen(s string, searchCount int, segment *routeSegment) int {
// check all from right to left segments
for i := segment.PartCount; i > 0 && searchCount > 0; i-- {
searchCount--
if constPosition := strings.LastIndex(s, segment.ComparePart); constPosition != -1 { //nolint:revive // Actually not simpler
if constPosition := strings.LastIndex(s, segment.ComparePart); constPosition != -1 {
s = s[:constPosition]
} else {
break