Public/Logging/Assert-KriticalUtcmIsNonInteractiveShell.ps1
|
<# .SYNOPSIS Kritical.UTCM wrapper over Microsoft365DSC helper Assert-M365DSCIsNonInteractiveShell (category: Logging, module: M365DSCLogEngine). .DESCRIPTION Thin delegating passthrough — logic stays in Microsoft365DSC upstream; Kritical.UTCM provides the friendly namespace + citation registration. Install-Module Microsoft365DSC -Scope CurrentUser BEFORE calling. .NOTES Category: Logging Module: M365DSCLogEngine Params: 0 #> function Assert-KriticalUtcmIsNonInteractiveShell { [CmdletBinding()] param() if (-not (Get-Command -Name 'Assert-M365DSCIsNonInteractiveShell' -ErrorAction SilentlyContinue)) { throw '[KriticalUtcm] Assert-M365DSCIsNonInteractiveShell not available — Install-Module Microsoft365DSC -Scope CurrentUser then re-run' } try { & 'Assert-M365DSCIsNonInteractiveShell' @PSBoundParameters } catch { Write-Error ('[KriticalUtcm/Assert-KriticalUtcmIsNonInteractiveShell] ' + 'Assert-M365DSCIsNonInteractiveShell' + ' failed: ' + $_.Exception.Message) throw } } |