K8s: Dashboards: Fix search parsing (#98560)

This commit is contained in:
Stephanie Hingtgen
2025-01-06 15:41:45 -06:00
committed by GitHub
parent 69af0f7ab6
commit c566e6af4e
2 changed files with 15 additions and 5 deletions
+7 -1
View File
@@ -310,7 +310,13 @@ func (s *SearchHandler) DoSearch(w http.ResponseWriter, r *http.Request) {
return
}
s.write(w, dashboardsvc.ParseResults(result, searchRequest.Offset))
parsedResults, err := dashboardsvc.ParseResults(result, searchRequest.Offset)
if err != nil {
errhttp.Write(ctx, err, w)
return
}
s.write(w, parsedResults)
}
func (s *SearchHandler) write(w http.ResponseWriter, obj any) {