From 2e2629730f5451ecb52b0c6e223d23f7b23a8e76 Mon Sep 17 00:00:00 2001 From: lonegunmanb Date: Fri, 19 May 2023 14:57:40 +0800 Subject: [PATCH] `data.azurerm_kubernetes_cluster` - Fix nil panic by correcting nil check expression (#21850) --- .../services/containers/kubernetes_cluster_data_source.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/services/containers/kubernetes_cluster_data_source.go b/internal/services/containers/kubernetes_cluster_data_source.go index 5aa4ed495fc0..dcc5279b968f 100644 --- a/internal/services/containers/kubernetes_cluster_data_source.go +++ b/internal/services/containers/kubernetes_cluster_data_source.go @@ -896,12 +896,12 @@ func flattenKubernetesClusterDataSourceStorageProfile(input *managedclusters.Man } diskVersion := "" - if input.FileCSIDriver != nil { + if input.DiskCSIDriver != nil { diskVersion = *input.DiskCSIDriver.Version } fileEnabled := true - if input.DiskCSIDriver != nil { + if input.FileCSIDriver != nil { fileEnabled = *input.FileCSIDriver.Enabled }