mirror of
https://github.com/restic/restic.git
synced 2026-08-05 21:33:16 +00:00
Apply go fix -any ./...
This commit is contained in:
@@ -30,7 +30,7 @@ var WithStack = errors.WithStack
|
||||
|
||||
// As finds the first error in err's tree that matches target, and if one is found,
|
||||
// sets target to that error value and returns true. Otherwise, it returns false.
|
||||
func As(err error, tgt interface{}) bool { return stderrors.As(err, tgt) }
|
||||
func As(err error, tgt any) bool { return stderrors.As(err, tgt) }
|
||||
|
||||
// Is reports whether any error in err's tree matches target.
|
||||
func Is(x, y error) bool { return stderrors.Is(x, y) }
|
||||
|
||||
@@ -33,7 +33,7 @@ func Fatal(s string) error {
|
||||
}
|
||||
|
||||
// Fatalf returns an error that is marked fatal, preserving an underlying error if passed.
|
||||
func Fatalf(s string, data ...interface{}) error {
|
||||
func Fatalf(s string, data ...any) error {
|
||||
// Use the last error found.
|
||||
var underlyingErr error
|
||||
for i := len(data) - 1; i >= 0; i-- {
|
||||
|
||||
Reference in New Issue
Block a user