Types/OpenPackage/get_Host.json.ps1

<#
.SYNOPSIS
    Gets a package's `host.json`
.DESCRIPTION
    Gets the content of any `host.json` files in the package.

    These files are used by Azure Functions
.LINK
    https://github.com/Azure/azure-functions-host/wiki/host.json-(v2)
#>

[OutputType([PSObject])]
param()

foreach ($part in $this.GetParts()) {
    if ($part.Uri -notmatch '/host\.json$') { continue }
        
    if ($part.Reader) {
        $part.Read()
    } else {
        $part
    }
}