Skip to content

Commit e9eb4bd

Browse files
fix
1 parent 7cf6140 commit e9eb4bd

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

samples/manage/azure-sql-db-managed-instance/prepare-subnet/prepareSubnet.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ function Ensure-Login ()
1212
If($context.Subscription -eq $null)
1313
{
1414
Write-Host "Loging in ..."
15-
If((Login-AzureRmAccount -ErrorAction SilentlyContinue) -eq $null)
15+
If((Login-AzureRmAccount -ErrorAction SilentlyContinue -ErrorVariable $error) -eq $null)
1616
{
17-
Write-Host "Login failed: $_" -ForegroundColor Red
17+
Write-Host "Login failed: $error" -ForegroundColor Red
1818
Exit
1919
}
2020
}

0 commit comments

Comments
 (0)