Fix Bug in Resource Ref Verifier (#3758)

Co-authored-by: Chidozie Ononiwu <chononiw@microsoft.com>
This commit is contained in:
Azure SDK Bot 2022-06-20 13:53:26 -07:00 committed by GitHub
parent 5f575c32fa
commit 3174833951
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -9,7 +9,7 @@ foreach ($file in $ymlfiles)
$ymlContent = Get-Content $file.FullName -Raw
$ymlObject = ConvertFrom-Yaml $ymlContent -Ordered
if ($ymlObject.Contains("resources"))
if ($ymlObject -and ($ymlObject.Contains("resources")))
{
if ($ymlObject["resources"]["repositories"])
{