1
0
mirror of https://github.com/labstack/echo.git synced 2025-04-07 07:09:57 +02:00

chore: fix some typos in comment (#2735)

Signed-off-by: zhuhaicity <zhuhai@52it.net>
This commit is contained in:
zhuhaicity 2025-01-12 15:28:38 +08:00 committed by GitHub
parent ee3e129778
commit ce0b12ae53
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 4 additions and 4 deletions

View File

@ -269,7 +269,7 @@ func (b *DefaultBinder) bindData(destination interface{}, data map[string][]stri
continue
}
// we could be dealing with pointer to slice `*[]string` so dereference it. There are wierd OpenAPI generators
// we could be dealing with pointer to slice `*[]string` so dereference it. There are weird OpenAPI generators
// that could create struct fields like that.
if structFieldKind == reflect.Pointer {
structFieldKind = structField.Elem().Kind()

2
ip.go
View File

@ -24,7 +24,7 @@ To retrieve IP address reliably/securely, you must let your application be aware
In Echo, this can be done by configuring `Echo#IPExtractor` appropriately.
This guides show you why and how.
> Note: if you dont' set `Echo#IPExtractor` explicitly, Echo fallback to legacy behavior, which is not a good choice.
> Note: if you don't set `Echo#IPExtractor` explicitly, Echo fallback to legacy behavior, which is not a good choice.
Let's start from two questions to know the right direction:

View File

@ -191,7 +191,7 @@ NewRateLimiterMemoryStoreWithConfig returns an instance of RateLimiterMemoryStor
with the provided configuration. Rate must be provided. Burst will be set to the rounded down value of
the configured rate if not provided or set to 0.
The build-in memory store is usually capable for modest loads. For higher loads other
The built-in memory store is usually capable for modest loads. For higher loads other
store implementations should be considered.
Characteristics:

View File

@ -2773,7 +2773,7 @@ func TestRouter_Routes(t *testing.T) {
func TestRouter_addEmptyPathToSlashReverse(t *testing.T) {
e := New()
r := e.router
r.add(http.MethodGet, "", "empty", handlerFunc) // emtpy path is normalized to `/`
r.add(http.MethodGet, "", "empty", handlerFunc) // empty path is normalized to `/`
assert.Equal(t, "/", r.Reverse("empty"))
}