1
0
mirror of https://github.com/kataras/iris.git synced 2025-12-18 10:27:06 +00:00

update code for go version 1.24

This commit is contained in:
Gerasimos (Makis) Maropoulos
2025-03-30 00:41:54 +02:00
parent e5e5d6f68f
commit 630c67ea6d
90 changed files with 337 additions and 167 deletions

View File

@@ -10,6 +10,9 @@ import (
"github.com/kataras/iris/v12/core/router"
"github.com/kataras/iris/v12/macro"
"golang.org/x/text/cases"
"golang.org/x/text/language"
)
const (
@@ -137,8 +140,8 @@ func parseMethod(macros *macro.Macros, fn reflect.Method, skipper func(string) b
}
func methodTitle(httpMethod string) string {
httpMethodFuncName := strings.Title(strings.ToLower(httpMethod))
return httpMethodFuncName
caser := cases.Title(language.English)
return caser.String(strings.ToLower(httpMethod))
}
var errSkip = errors.New("skip")