d-g-town пре 2 година
родитељ
комит
a5e6b60d45
1 измењених фајлова са 5 додато и 0 уклоњено
  1. 5 0
      api/server/handlers/cluster/notify_resolved_incident.go

+ 5 - 0
api/server/handlers/cluster/notify_resolved_incident.go

@@ -36,8 +36,13 @@ func NewNotifyResolvedIncidentHandler(
 }
 
 func (c *NotifyResolvedIncidentHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
+	project, _ := r.Context().Value(types.ProjectScope).(*models.Project)
 	cluster, _ := r.Context().Value(types.ClusterScope).(*models.Cluster)
 
+	if project.GetFeatureFlag(models.ValidateApplyV2, c.Config().LaunchDarklyClient) {
+		return
+	}
+
 	request := &types.Incident{}
 
 	if ok := c.DecodeAndValidate(w, r, request); !ok {