diff --git a/api/scaling-history-api.openapi.yaml b/api/scaling-history-api.openapi.yaml index 16879503dd..9ee40b9d86 100644 --- a/api/scaling-history-api.openapi.yaml +++ b/api/scaling-history-api.openapi.yaml @@ -51,7 +51,7 @@ paths: schema: type: string enum: ["asc", "desc"] - deprecated: true + deprecated: true example: order=desc - name: page in: query diff --git a/src/autoscaler/api/publicapiserver/scaling_history_handler.go b/src/autoscaler/api/publicapiserver/scaling_history_handler.go index 9d83ed7af5..ae7b1824ea 100644 --- a/src/autoscaler/api/publicapiserver/scaling_history_handler.go +++ b/src/autoscaler/api/publicapiserver/scaling_history_handler.go @@ -46,9 +46,9 @@ func NewScalingHistoryHandler(logger lager.Logger, conf *config.Config) (*Scalin func (h *ScalingHistoryHandler) NewError(_ context.Context, _ error) *scalinghistory.ErrorResponseStatusCode { result := &scalinghistory.ErrorResponseStatusCode{} - result.SetStatusCode(500) + result.SetStatusCode(http.StatusInternalServerError) result.SetResponse(scalinghistory.ErrorResponse{ - Code: scalinghistory.NewOptString(http.StatusText(500)), + Code: scalinghistory.NewOptString(http.StatusText(http.StatusInternalServerError)), Message: scalinghistory.NewOptString("Error retrieving scaling history from scaling engine"), }) return result