From 308a339762f1eba3491a27395f65b3014868b7b7 Mon Sep 17 00:00:00 2001 From: Jesper Fajers Date: Wed, 7 Feb 2024 11:08:37 +0000 Subject: [PATCH] Update --- src/functions/Initialize-AzOpsEnvironment.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/functions/Initialize-AzOpsEnvironment.ps1 b/src/functions/Initialize-AzOpsEnvironment.ps1 index d1931d79..d0939a6b 100644 --- a/src/functions/Initialize-AzOpsEnvironment.ps1 +++ b/src/functions/Initialize-AzOpsEnvironment.ps1 @@ -132,7 +132,7 @@ } if ($currentPrincipal.id) { try { - $rootPermissions = Get-AzRoleAssignment -ObjectId $currentPrincipal.id -Scope "/" -ErrorAction -ErrorAction Stop + $rootPermissions = Get-AzRoleAssignment -ObjectId $currentPrincipal.id -Scope "/" -ErrorAction Stop } catch { Write-AzOpsMessage -LogLevel InternalComment -LogString 'Initialize-AzOpsEnvironment.CurrentPrincipal.RoleAssignmentFail' -LogStringValues $_