Skip to content

Commit b2b048d

Browse files
Handle unsupported auth types gracefully in ratelimit.ps1
1 parent 3a4cf93 commit b2b048d

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

src/ratelimit.ps1

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,11 @@ try {
1818
Write-Output $fenceStart
1919

2020
LogGroup " - Rate Limit ($label)" {
21-
Get-GitHubRateLimit | Format-Table -AutoSize | Out-String
21+
try {
22+
Get-GitHubRateLimit | Format-Table -AutoSize | Out-String
23+
} catch {
24+
Write-Warning "Could not retrieve rate limit information: $($_.Exception.Message)"
25+
}
2226
}
2327

2428
$fenceEnd = '' + ('' * ($fenceStart.Length - 2)) + ''

0 commit comments

Comments
 (0)