(value any)
| 112 | } |
| 113 | |
| 114 | func optionalString(value any) *string { |
| 115 | if value == nil { |
| 116 | return nil |
| 117 | } |
| 118 | text := strings.TrimSpace(fmt.Sprint(value)) |
| 119 | if text == "" { |
| 120 | return nil |
| 121 | } |
| 122 | return &text |
| 123 | } |
| 124 | |
| 125 | func coerceModel(value any) *string { |
| 126 | result := optionalString(value) |
no outgoing calls
no test coverage detected