Skip to content

Commit

Permalink
Check if header is set
Browse files Browse the repository at this point in the history
Co-Authored-By: Olivier Bellone <[email protected]>
  • Loading branch information
rattrayalex-stripe and ob-stripe authored Oct 5, 2019
1 parent dd58835 commit 5c2da7c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/HttpClient/CurlClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,7 @@ private function shouldRetry($errno, $rcode, $rheaders, $numRetries)

// The API may ask us not to retry (eg; if doing so would be a no-op)
// or advise us to retry (eg; in cases of lock timeouts); we defer to that.
if ($rheaders['stripe-should-retry'] === 'false') {
if (isset($rheaders['stripe-should-retry']) && $rheaders['stripe-should-retry'] === 'false') {
return false;
}
if ($rheaders['stripe-should-retry'] === 'true') {
Expand Down

0 comments on commit 5c2da7c

Please sign in to comment.