summaryrefslogtreecommitdiff
path: root/app/models/clusters/applications/knative.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/models/clusters/applications/knative.rb')
-rw-r--r--app/models/clusters/applications/knative.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/models/clusters/applications/knative.rb b/app/models/clusters/applications/knative.rb
index 6867d7b6934..0e7cbb35e47 100644
--- a/app/models/clusters/applications/knative.rb
+++ b/app/models/clusters/applications/knative.rb
@@ -141,13 +141,13 @@ module Clusters
end
def install_knative_metrics
- return [] unless cluster.application_prometheus_available?
+ return [] unless cluster.application_prometheus&.available?
[Gitlab::Kubernetes::KubectlCmd.apply_file(METRICS_CONFIG)]
end
def delete_knative_istio_metrics
- return [] unless cluster.application_prometheus_available?
+ return [] unless cluster.application_prometheus&.available?
[Gitlab::Kubernetes::KubectlCmd.delete("--ignore-not-found", "-f", METRICS_CONFIG)]
end