mirror of
https://github.com/go-kratos/kratos.git
synced 2026-05-22 10:15:24 +02:00
fix: fix some typos (#1869)
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
<a href="https://github.com/go-kratos/kratos/actions"><img src="https://github.com/go-kratos/kratos/workflows/Go/badge.svg" alt="Build Status"></a>
|
||||
<a href="https://pkg.go.dev/github.com/go-kratos/kratos/v2"><img src="https://pkg.go.dev/badge/github.com/go-kratos/kratos/v2" alt="GoDoc"></a>
|
||||
<a href="https://codecov.io/gh/go-kratos/kratos"><img src="https://codecov.io/gh/go-kratos/kratos/master/graph/badge.svg" alt="codeCov"></a>
|
||||
<a href="https://goreportcard.com/report/github.com/go-kratos/kratos"><img src="https://goreportcard.com/badge/github.com/go-kratos/kratos" alt="Go Report Card" /a>
|
||||
<a href="https://goreportcard.com/report/github.com/go-kratos/kratos"><img src="https://goreportcard.com/badge/github.com/go-kratos/kratos" alt="Go Report Card"></a>
|
||||
<a href="https://github.com/go-kratos/kratos/blob/main/LICENSE"><img src="https://img.shields.io/github/license/go-kratos/kratos" alt="License"></a>
|
||||
<a href="https://github.com/avelino/awesome-go"><img src="https://awesome.re/mentioned-badge.svg" alt="Awesome Go"></a>
|
||||
<a href="https://discord.gg/BWzJsUJ"><img src="https://img.shields.io/discord/766619759214854164?label=chat&logo=discord" alt="Discord"></a>
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@
|
||||
<a href="https://github.com/go-kratos/kratos/actions"><img src="https://github.com/go-kratos/kratos/workflows/Go/badge.svg" alt="Build Status"></a>
|
||||
<a href="https://pkg.go.dev/github.com/go-kratos/kratos/v2"><img src="https://pkg.go.dev/badge/github.com/go-kratos/kratos/v2" alt="GoDoc"></a>
|
||||
<a href="https://codecov.io/gh/go-kratos/kratos"><img src="https://codecov.io/gh/go-kratos/kratos/master/graph/badge.svg" alt="codeCov"></a>
|
||||
<a href="https://goreportcard.com/report/github.com/go-kratos/kratos"><img src="https://goreportcard.com/badge/github.com/go-kratos/kratos" alt="Go Report Card" /a>
|
||||
<a href="https://goreportcard.com/report/github.com/go-kratos/kratos"><img src="https://goreportcard.com/badge/github.com/go-kratos/kratos" alt="Go Report Card"></a>
|
||||
<a href="https://github.com/go-kratos/kratos/blob/main/LICENSE"><img src="https://img.shields.io/github/license/go-kratos/kratos" alt="License"></a>
|
||||
<a href="https://github.com/avelino/awesome-go"><img src="https://awesome.re/mentioned-badge.svg" alt="Awesome Go"></a>
|
||||
<a href="https://discord.gg/BWzJsUJ"><img src="https://img.shields.io/discord/766619759214854164?label=chat&logo=discord" alt="Discord"></a>
|
||||
|
||||
+1
-1
@@ -69,7 +69,7 @@ func Errorf(code int, reason, format string, a ...interface{}) error {
|
||||
return New(code, reason, fmt.Sprintf(format, a...))
|
||||
}
|
||||
|
||||
// Code returns the http code for a error.
|
||||
// Code returns the http code for an error.
|
||||
// It supports wrapped errors.
|
||||
func Code(err error) int {
|
||||
if err == nil {
|
||||
|
||||
+1
-1
@@ -8,7 +8,7 @@ import (
|
||||
var global = &loggerAppliance{}
|
||||
|
||||
// loggerAppliance is the proxy of `Logger` to
|
||||
// make logger change will effect to all sub-logger.
|
||||
// make logger change will affect all sub-logger.
|
||||
type loggerAppliance struct {
|
||||
lock sync.Mutex
|
||||
Logger
|
||||
|
||||
+1
-1
@@ -28,7 +28,7 @@ func Value(ctx context.Context, v interface{}) interface{} {
|
||||
return v
|
||||
}
|
||||
|
||||
// Caller returns returns a Valuer that returns a pkg/file:line description of the caller.
|
||||
// Caller returns a Valuer that returns a pkg/file:line description of the caller.
|
||||
func Caller(depth int) Valuer {
|
||||
return func(context.Context) interface{} {
|
||||
d := depth
|
||||
|
||||
Reference in New Issue
Block a user