(value T)
| 291 | } |
| 292 | } |
| 293 | |
| 294 | func cloneProperties(properties map[string]any) map[string]any { |
| 295 | cloned := make(map[string]any, len(properties)) |
| 296 | for key, value := range properties { |
| 297 | cloned[key] = value |
| 298 | } |
| 299 | return cloned |
| 300 | } |
| 301 | |
| 302 | func cloneJSON[T any](value T) T { |
| 303 | data, err := json.Marshal(value) |
| 304 | if err != nil { |
| 305 | panic(err) |
| 306 | } |