File tree 2 files changed +3
-2
lines changed 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -596,7 +596,7 @@ function Get-VirtualMachines
596
596
597
597
foreach ($Item in $VmList )
598
598
{
599
- if (($null -ne $Item.Extensions ) -and
599
+ if (($null -ne $Item.Extensions -and $Item .Extensions.Count -gt 0 ) -and
600
600
($Item.Extensions.Id | ForEach-Object { `
601
601
$_.split (' /' )[-1 ].tolower().contains( `
602
602
[ConstantStrings ]::adeExtensionPrefix)}) -contains $true )
@@ -2103,4 +2103,4 @@ finally
2103
2103
$MyInvocation ,
2104
2104
" CopyKeys completed - $EndTime ." ,
2105
2105
[LogType ]::INFO)
2106
- }
2106
+ }
Original file line number Diff line number Diff line change @@ -15,3 +15,4 @@ This script copies the disk encryption keys and key encryption keys for Azure Di
15
15
| 02/23 | - Fixed GUI issues in case of varying resolution.</br > - Fixed login bug in case of expired context. |
16
16
| 02/28 | - Removing hardcoded vault endpoint and replacing it with one provided by KeyVault RP. |
17
17
| 04/09 | - Providing MoveCollection MSI with appropriate target key vault access in case the script is used for Azure Resource Mover. |
18
+ |30/10/2023 | - Handling case when extensions list is empty but not null
You can’t perform that action at this time.
0 commit comments