Skip to content

Commit 3626906

Browse files
committed
fix graph preset saving
1 parent 44c8c43 commit 3626906

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Tenant/Tools/Invoke-ExecGraphExplorerPreset.ps1

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ Function Invoke-ExecGraphExplorerPreset {
1212

1313
$APIName = $Request.Params.CIPPEndpoint
1414
Write-LogMessage -headers $Request.Headers -API $APINAME -message 'Accessed this API' -Sev 'Debug'
15-
#UNDOREPLACE
16-
$Username = ([System.Text.Encoding]::UTF8.GetString([System.Convert]::FromBase64String($request.headers.'x-ms-client-principal')) | ConvertFrom-Json).userDetails
17-
# Write to the Azure Functions log stream.
18-
Write-Host 'PowerShell HTTP trigger function processed a request.'
15+
$Username = $request.headers.'x-ms-client-principal-name'
16+
1917
$Action = $Request.Body.Action ?? ''
2018

19+
Write-Information ($Request.Body | ConvertTo-Json -Depth 10)
20+
2121
switch ($Action) {
2222
'Copy' {
2323
$Id = $Request.Body.preset.id ? $Request.Body.preset.id: (New-Guid).Guid

0 commit comments

Comments
 (0)