File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -160,8 +160,10 @@ function Add-Link {
160
160
161
161
$Link = " > [!NOTE]`n > $LinkTitle [$CommandRename ]($BaseUrl /$FullModuleName$View )`r`n`n ## SYNTAX"
162
162
$LinkOnEndOfDoc = " ## RELATED LINKS`r`n [$CommandRename ]($BaseUrl /$FullModuleName$View )"
163
+ $Folder = $View.Split (" =" )[1 ]
164
+ $ConfirmFile = Join-Path $WorkLoadDocsPath " $Folder " " $FullModuleName " " $BetaCommand .md"
163
165
$ConfirmCommandAvailability = Find-MgGraphCommand - Command $CommandRename
164
- if ($ConfirmCommandAvailability ) {
166
+ if ($ConfirmCommandAvailability -and ( Test-Path $ConfirmFile ) ) {
165
167
(Get-Content $File ) |
166
168
Foreach-Object { $_ -replace ' ## SYNTAX' , $Link -replace ' ## RELATED LINKS' , $LinkOnEndOfDoc } |
167
169
Out-File $File
You can’t perform that action at this time.
0 commit comments