Skip to content

Commit f05c006

Browse files
committed
Remove null check
1 parent 75c89ba commit f05c006

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

samples/batch/Invoke-BatchWithRetry.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ function Invoke-BatchWithRetry {
88
$pending = @($BatchRequests) # Ensure it's an array
99
$retryCount = 0
1010

11-
while ($pending -ne $null -and $pending.Count -gt 0 -and $retryCount -le $MaxRetries) {
11+
while ($pending.Count -gt 0 -and $retryCount -le $MaxRetries) {
1212
$batchBody = @{
1313
requests = $pending
1414
} | ConvertTo-Json -Depth 5
@@ -25,7 +25,7 @@ function Invoke-BatchWithRetry {
2525
}
2626
}
2727

28-
if ($pending -ne $null -and $pending.Count -gt 0) {
28+
if ($pending.Count -gt 0) {
2929
Start-Sleep -Seconds 5
3030
$retryCount++
3131
}

0 commit comments

Comments
 (0)