MCPcopy
hub / github.com/cortexlabs/cortex / AddErrors

Function AddErrors

pkg/lib/errors/multi.go:28–37  ·  view source on GitHub ↗
(errs []error, newErrs []error, strs ...string)

Source from the content-addressed store, hash-verified

26}
27
28func AddErrors(errs []error, newErrs []error, strs ...string) ([]error, bool) {
29 ok := false
30 for _, err := range newErrs {
31 if err != nil {
32 errs = append(errs, Wrap(err, strs...))
33 ok = true
34 }
35 }
36 return errs, ok
37}
38
39func WrapAll(errs []error, strs ...string) []error {
40 if !HasError(errs) {

Callers 4

StructFunction · 0.92
StructListFunction · 0.92
InterfaceStructListFunction · 0.92
StructFromStringMapFunction · 0.92

Calls 1

WrapFunction · 0.85

Tested by

no test coverage detected