We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c1f5176 commit 864d397Copy full SHA for 864d397
functions/image/Remove-PSDCImage.ps1
@@ -272,14 +272,8 @@
272
273
$imageData = $imageData | Where-Object {$_.ImageID -ne $item.ImageID}
274
275
- # Get the json file
276
- $jsonFolder = Get-PSFConfigValue -FullName psdatabaseclone.informationstore.path
277
-
278
- # Create a PS Drive
279
- $null = New-PSDrive -Name JSONFolder -Root $jsonFolder -Credential $Credential -PSProvider FileSystem
280
281
# Set the image file
282
- $jsonImageFile = JSONFolder:\images.json
+ $jsonImageFile = "JSONFolder:\images.json"
283
284
# Convert the data back to JSON
285
if ($newImageData.Count -ge 1) {
@@ -289,9 +283,6 @@
289
Clear-Content -Path $jsonImageFile
290
}
291
292
- # Remove the PS Drive
293
- $null = Remove-PSDrive -Name JSONFolder
294
295
286
296
287
297
288
0 commit comments