mirror of
https://github.com/php-curl-class/php-curl-class.git
synced 2026-10-04 02:57:15 +00:00
Use short array syntax
This commit is contained in:
+2
-2
@@ -6,11 +6,11 @@ use Curl\Curl;
|
||||
// curl --request PATCH "https://httpbin.org/patch" --data "a=1&b=2&c=3"
|
||||
|
||||
$curl = new Curl();
|
||||
$curl->patch('https://httpbin.org/patch', array(
|
||||
$curl->patch('https://httpbin.org/patch', [
|
||||
'a' => '1',
|
||||
'b' => '2',
|
||||
'c' => '3',
|
||||
));
|
||||
]);
|
||||
|
||||
if ($curl->error) {
|
||||
echo 'Error: ' . $curl->errorCode . ': ' . $curl->errorMessage . "\n";
|
||||
|
||||
Reference in New Issue
Block a user