Skip to content

Commit e9d4eab

Browse files
🩹 [Refactor]: Improve module name assignment logic in Get-Settings workflow
1 parent cee2e4d commit e9d4eab

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

‎.github/workflows/Get-Settings.yml‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,13 @@ jobs:
131131
RepositoryName = $env:GITHUB_REPOSITORY_NAME
132132
} | Format-List | Out-String
133133
134-
$name = ![string]::IsNullOrEmpty($inputName) ? $name : ![string]::IsNullOrEmpty($settings.Name) ? $settings.Name : $env:GITHUB_REPOSITORY_NAME
134+
if (![string]::IsNullOrEmpty($inputName)) {
135+
$name = $inputName
136+
} elseif (![string]::IsNullOrEmpty($settings.Name)) {
137+
$name = $settings.Name
138+
} else {
139+
$name = $env:GITHUB_REPOSITORY_NAME
140+
}
135141
136142
Write-Host "Using [$name] as the module name."
137143
}

0 commit comments

Comments
 (0)