Actually return errors

main
Max Ignatenko 2024-02-16 08:50:37 +00:00
parent 8313c74482
commit 37ccca4c2f
1 changed files with 2 additions and 0 deletions

View File

@ -40,6 +40,8 @@ func (r *fallbackResolver) GetDocument(ctx context.Context, didstr string) (*did
for _, res := range r.resolvers { for _, res := range r.resolvers {
if d, err := res.GetDocument(ctx, didstr); err == nil { if d, err := res.GetDocument(ctx, didstr); err == nil {
return d, nil return d, nil
} else {
errs = append(errs, err)
} }
} }
return nil, errors.Join(errs...) return nil, errors.Join(errs...)