summaryrefslogtreecommitdiff
path: root/app/models
diff options
context:
space:
mode:
Diffstat (limited to 'app/models')
-rw-r--r--app/models/clusters/platforms/kubernetes.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/models/clusters/platforms/kubernetes.rb b/app/models/clusters/platforms/kubernetes.rb
index 8b00f1dac0b..a33534da8bb 100644
--- a/app/models/clusters/platforms/kubernetes.rb
+++ b/app/models/clusters/platforms/kubernetes.rb
@@ -58,7 +58,7 @@ module Clusters
def update_kubernetes_integration!
raise 'Kubernetes service already configured' unless manages_kubernetes_service?
- ensure_kubernetes_service.update!(
+ ensure_kubernetes_service&.update!(
active: enabled?,
api_url: api_url,
namespace: namespace,
@@ -83,7 +83,7 @@ module Clusters
def destroy_kubernetes_integration!
return unless manages_kubernetes_service?
- kubernetes_service.destroy!
+ kubernetes_service&.destroy!
end
def kubernetes_service