diff --git a/http3/error.go b/http3/error.go index b96ebeec..82fdae6a 100644 --- a/http3/error.go +++ b/http3/error.go @@ -33,6 +33,11 @@ func (e *Error) Error() string { return s } +func (e *Error) Is(target error) bool { + t, ok := target.(*Error) + return ok && e.ErrorCode == t.ErrorCode && e.Remote == t.Remote +} + func maybeReplaceError(err error) error { if err == nil { return nil