diff options
author | Runxi Yu <me@runxiyu.org> | 2025-03-21 14:58:42 +0800 |
---|---|---|
committer | Runxi Yu <me@runxiyu.org> | 2025-03-21 14:58:42 +0800 |
commit | f1247b104a0dba8226c443d876737ee924db6a1d (patch) | |
tree | 3fe084071d64ae30d0ffd12a8f10da30ae6d113f /misc/errors.go | |
parent | mailkit: Remove underscores (diff) | |
download | go-lindenii-common-f1247b104a0dba8226c443d876737ee924db6a1d.tar.gz go-lindenii-common-f1247b104a0dba8226c443d876737ee924db6a1d.tar.zst go-lindenii-common-f1247b104a0dba8226c443d876737ee924db6a1d.zip |
misc: Remove underscores
Diffstat (limited to 'misc/errors.go')
-rw-r--r-- | misc/errors.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/misc/errors.go b/misc/errors.go index 8434637..190f8ba 100644 --- a/misc/errors.go +++ b/misc/errors.go @@ -2,11 +2,11 @@ package misc import "fmt" -func Wrap_one_error(a error, b error) error { +func WrapOneError(a error, b error) error { return fmt.Errorf("%w: %w", a, b) } -func First_or_panic[T any](v T, err error) T { +func FirstOrPanic[T any](v T, err error) T { if err != nil { panic(err) } |