(err interface {
WithAttributes(kv ...any) *errors.Error
},
)
| 39 | type valueErr func(any) *errors.Error |
| 40 | |
| 41 | func unexpectedValue(err interface { |
| 42 | WithAttributes(kv ...any) *errors.Error |
| 43 | }, |
| 44 | ) valueErr { |
| 45 | return func(value any) *errors.Error { |
| 46 | return err.WithAttributes(valueKey, value) |
| 47 | } |
| 48 | } |
| 49 | |
| 50 | func errExpectedLowerOrEqual(lorawanField string, max any) valueErr { |
| 51 | return unexpectedValue(errFieldHasMax.WithAttributes("lorawan_field", lorawanField, "max", max)) |
no test coverage detected