Skip to content

Commit 6c64683

Browse files
authored
Fix the issue that build will fail when delete a module. (#15595)
Co-authored-by: wyunchi-ms <[email protected]>
1 parent a953e9a commit 6c64683

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tools/PrepareAutorestModule.ps1

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,9 @@ foreach ($Module in $ModuleList)
8181
$ModuleFolder = (Get-ChildItem -path $ModuleFolder -filter Az.$Module.psd1 -Recurse).Directory
8282
if ($Null -eq $ModuleFolder)
8383
{
84-
Throw "Cannot find Az.$Module.psd1 in $ModuleFolder."
84+
# Module is not found maybe it's deleted in this PR
85+
Write-Warning "Cannot find Az.$Module.psd1 in $ModuleFolder."
86+
continue
8587
}
8688
Set-Location -Path $ModuleFolder
8789
try

0 commit comments

Comments
 (0)