From a5d8296b6dcfff489941aaa1d4c0a69e01a3fe7b Mon Sep 17 00:00:00 2001 From: Patrik Cyvoct Date: Wed, 12 Feb 2020 13:17:31 +0100 Subject: [PATCH] fix(k8s): fix requirements for auto upgrade Signed-off-by: Patrik Cyvoct --- scaleway/resource_k8s_cluster_beta.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scaleway/resource_k8s_cluster_beta.go b/scaleway/resource_k8s_cluster_beta.go index f9794a2e9..f65eb939f 100644 --- a/scaleway/resource_k8s_cluster_beta.go +++ b/scaleway/resource_k8s_cluster_beta.go @@ -362,7 +362,7 @@ func resourceScalewayK8SClusterBetaCreate(d *schema.ResourceData, m interface{}) // check if either all or none of the auto upgrade attribute are set. // if one auto upgrade attribute is set, they all must be set. // if none is set, auto upgrade attributes will be computed. - if okAutoUpgradeEnable == okAutoUpgradeDay && okAutoUpgradeEnable == okAutoUpgradeStartHour { + if okAutoUpgradeEnable != okAutoUpgradeDay || okAutoUpgradeEnable != okAutoUpgradeStartHour { return fmt.Errorf("all field or zero field of auto_upgrade must be set") }