summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrishichawda <rishichawda@users.noreply.github.com>2021-11-19 18:49:53 +0530
committerrishichawda <rishichawda@users.noreply.github.com>2021-11-19 18:49:53 +0530
commit8b0cb6f585c9159cd2c5b2b9a78b27ca0039246f (patch)
treecf1d2ae717af2d063ef63f92fccb21cc362eabab
parent1ddda062591c6225f44efe676a3edf9ea1d12411 (diff)
downloadchef-8b0cb6f585c9159cd2c5b2b9a78b27ca0039246f.tar.gz
remove convert to json command
Signed-off-by: rishichawda <rishichawda@users.noreply.github.com>
-rw-r--r--lib/chef/resource/windows_feature_powershell.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/resource/windows_feature_powershell.rb b/lib/chef/resource/windows_feature_powershell.rb
index a7a9a60e50..70c7de5783 100644
--- a/lib/chef/resource/windows_feature_powershell.rb
+++ b/lib/chef/resource/windows_feature_powershell.rb
@@ -215,7 +215,7 @@ class Chef
# fetch the list of available feature names and state in JSON and parse the JSON
def parsed_feature_list
# Grab raw feature information from WindowsFeature
- raw_list_of_features = powershell_exec!("Get-WindowsFeature | Select-Object -Property Name,InstallState | ConvertTo-Json -Compress", timeout: new_resource.timeout).result
+ raw_list_of_features = powershell_exec!("Get-WindowsFeature | Select-Object -Property Name,InstallState", timeout: new_resource.timeout).result
Chef::JSONCompat.from_json(raw_list_of_features)
end