1
0
Fork 0

Check for returned link header in GithubDriver

pull/10088/head
Alexander Schranz 2021-09-02 19:17:17 +02:00 committed by GitHub
parent 5b16d61762
commit 99c6b450e6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -576,6 +576,10 @@ class GitHubDriver extends VcsDriver
{ {
$header = $response->getHeader('link'); $header = $response->getHeader('link');
if (!$header) {
return;
}
$links = explode(',', $header); $links = explode(',', $header);
foreach ($links as $link) { foreach ($links as $link) {
if (preg_match('{<(.+?)>; *rel="next"}', $link, $match)) { if (preg_match('{<(.+?)>; *rel="next"}', $link, $match)) {