(w http.ResponseWriter, status int, v any)
| 654 | } |
| 655 | |
| 656 | func writeJSON(w http.ResponseWriter, status int, v any) { |
| 657 | w.Header().Set("Content-Type", "application/json") |
| 658 | w.WriteHeader(status) |
| 659 | _ = json.NewEncoder(w).Encode(v) |
| 660 | } |
| 661 | |
| 662 | func writeError(w http.ResponseWriter, status int, requestID, code, message string) { |
| 663 | writeJSON(w, status, map[string]any{ |
no test coverage detected