Skip to content

Commit 404000a

Browse files
committed
🚿
1 parent 2d2e591 commit 404000a

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

examples/curl_multi.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@
1313
use chillerlan\HTTP\CurlUtils\{CurlMultiClient, MultiResponseHandlerInterface};
1414
use chillerlan\HTTP\HTTPOptions;
1515
use chillerlan\HTTP\Psr18\CurlClient;
16-
use chillerlan\HTTP\Psr7\Request;
16+
use chillerlan\HTTP\Psr7\{Request, Query};
1717
use Psr\Http\Message\{RequestInterface, ResponseInterface};
18-
use function chillerlan\HTTP\Psr7\{build_http_query, get_json};
18+
use function chillerlan\HTTP\Psr7\get_json;
1919

2020
require_once __DIR__.'/../vendor/autoload.php';
2121

@@ -43,7 +43,7 @@
4343

4444
foreach(array_chunk(get_json($itemResponse), 200) as $chunk){
4545
foreach($languages as $lang){
46-
$requests[] = new Request('GET', $endpoint.'?'.build_http_query(['lang' => $lang, 'ids' => implode(',', $chunk)]));
46+
$requests[] = new Request('GET', $endpoint.'?'.Query::build(['lang' => $lang, 'ids' => implode(',', $chunk)]));
4747
}
4848
}
4949

src/Psr7/Uri.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
use Psr\Http\Message\UriInterface;
1515

1616
use function call_user_func_array, explode, filter_var, is_array, is_string, ltrim, parse_url,
17-
preg_replace_callback, rawurlencode, strpos, strtolower, ucfirst;
17+
preg_replace_callback, rawurlencode, strpos, strtolower, ucfirst, var_export;
1818

1919
use const FILTER_FLAG_IPV6, FILTER_VALIDATE_IP;
2020

@@ -52,7 +52,7 @@ public function __construct($uri = null){
5252
}
5353

5454
if(!is_array($uri)){
55-
throw new InvalidArgumentException('invalid URI: "'.$uri.'"');
55+
throw new InvalidArgumentException('invalid URI: '.var_export($uri, true));
5656
}
5757

5858
$this->parseUriParts($uri);

0 commit comments

Comments
 (0)