(f reflect.StructField, tag string, def string)
| 384 | } |
| 385 | |
| 386 | func stringTag(f reflect.StructField, tag string, def string) string { |
| 387 | if v := f.Tag.Get(tag); v != "" { |
| 388 | return v |
| 389 | } |
| 390 | return def |
| 391 | } |
| 392 | |
| 393 | // ensureType panics if the given value does not match the JSON Schema type. |
| 394 | func ensureType(r Registry, fieldName string, s *Schema, value string, v any) { |
no test coverage detected
searching dependent graphs…