File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 111111 Write-PSFMessage - Message " Started removing database images" - Level Verbose
112112
113113 # Get all the items
114- $items = Get-PSDCImage - PSDCSqlCredential $pdcCredential
114+ $items = Get-PSDCImage
115115
116116 if ($ImageID ) {
117117 Write-PSFMessage - Message " Filtering image ids" - Level Verbose
216216 Stop-PSFFunction - Message " Couldn't retrieve clone records for host $ ( $result.HostName ) " - ErrorRecord $_ - Target $hst - Continue
217217 }
218218
219- if ($PSCmdlet.ShouldProcess ($item.ImageLocation , " Removing image ' $ ( $item .ImageLocation ) ' from system" )) {
219+ if ($PSCmdlet.ShouldProcess ($item.ImageLocation , " Removing image from system" )) {
220220 # Remove the image from the file system
221221 try {
222222 if ($computer.IsLocalhost ) {
247247 }
248248 }
249249
250- if ($PSCmdlet.ShouldProcess ($item.ImageLocation , " Removing image from system database" )) {
250+ if ($PSCmdlet.ShouldProcess ($item.ImageLocation , " Removing image from database" )) {
251251 # Remove the image from the database
252252 try {
253253 $query = " DELETE FROM dbo.Image WHERE ImageID = $ ( $item.ImageID ) "
You can’t perform that action at this time.
0 commit comments