3.1.1 fixes

Fix issue with getting user information calling the ME API with full ODATA info
This commit is contained in:
Mikael Karlsson
2021-06-16 12:14:01 +10:00
parent 18533494b2
commit a495b0f0df
11 changed files with 525 additions and 30 deletions

View File

@@ -275,6 +275,7 @@ function Invoke-InitializeModule
AssignmentsType = "deviceManagementScriptAssignments"
Icon="CustomAttributes"
GroupId = "CustomAttributes" # MacOS Settings
DetailExtension = { Add-ScriptExtensions @args }
})
Add-ViewItem (New-Object PSObject -Property @{
@@ -1044,8 +1045,9 @@ function Invoke-DownloadScript
$dlgSave.InitialDirectory = Get-SettingValue "IntuneRootFolder" $env:Temp
$dlgSave.FileName = $obj.FileName
if($dlgSave.ShowDialog() -eq [System.Windows.Forms.DialogResult]::OK -and $dlgSave.Filename)
{
[System.Text.Encoding]::ASCII.GetString([System.Convert]::FromBase64String($obj.scriptContent)) | Out-File $dlgSave.Filename -Force
{
# Changed to WriteAllBytes to get rid of BOM characters from Custom Attribute file
[IO.File]::WriteAllBytes($dlgSave.FileName, ([System.Convert]::FromBase64String($obj.scriptContent)))
}
}
}