feat: add errorx.In to facility error checking (#4105)

This commit is contained in:
Kevin Wan
2024-04-27 20:43:45 +08:00
committed by GitHub
parent b337ae36e5
commit bfddb9dae4
7 changed files with 97 additions and 22 deletions

View File

@@ -2372,7 +2372,7 @@ func withHook(hook red.Hook) Option {
}
func acceptable(err error) bool {
return err == nil || errors.Is(err, red.Nil) || errors.Is(err, context.Canceled)
return err == nil || errorx.In(err, red.Nil, context.Canceled)
}
func getRedis(r *Redis) (RedisNode, error) {