Dependencies/EPS/0.5.0/Get-OrElse.ps1
function Get-OrElse { [CmdletBinding()] Param( [Parameter(ValueFromPipeline = $True)] [Object]$Value, [Parameter(Mandatory = $True)] [Object]$Default ) if ([string]::IsNullOrEmpty($Value)) { $Default } else { $Value } } |