Skip to content

Commit 8f40324

Browse files
Update scripts/helpers/Publish-PSModule.ps1
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent d405e6b commit 8f40324

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

scripts/helpers/Publish-PSModule.ps1

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,9 @@
8787
}
8888

8989
Set-GitHubLogGroup 'Event information - Details' {
90+
if (-not $pull_request) {
91+
throw 'GitHub event does not contain pull_request data. This script must be run from a pull_request event.'
92+
}
9093
$prHeadRef = $pull_request.head.ref
9194

9295
Write-Output '-------------------------------------------------'

0 commit comments

Comments
 (0)