@@ 59-64 (lines=6) @@ | ||
56 | 'next' => false, |
|
57 | 'last' => false, |
|
58 | ]; |
|
59 | foreach (explode(', ', $response->getHeader('link')[0]) as $link) { |
|
60 | list($url, $rel) = explode('>; rel="', ltrim(rtrim($link, '"'), '<')); |
|
61 | if (isset($links[$rel])) { |
|
62 | $links[$rel] = $url; |
|
63 | } |
|
64 | } |
|
65 | ||
66 | if ($links['next'] === false || $links['last'] === false) { |
|
67 | return; |
|
@@ 114-119 (lines=6) @@ | ||
111 | 'next' => false, |
|
112 | 'last' => false, |
|
113 | ]; |
|
114 | foreach (explode(', ', $response->getHeader('link')[0]) as $link) { |
|
115 | list($url, $rel) = explode('>; rel="', ltrim(rtrim($link, '"'), '<')); |
|
116 | if (isset($links[$rel])) { |
|
117 | $links[$rel] = $url; |
|
118 | } |
|
119 | } |
|
120 | ||
121 | if ($links['next'] === false || $links['last'] === false) { |
|
122 | $subject->onCompleted(); |