We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent dafefdb commit c9206f0Copy full SHA for c9206f0
src/Formatter/CurlCommandFormatter.php
@@ -45,7 +45,12 @@ public function formatRequest(RequestInterface $request)
45
} else {
46
$data = '[non-seekable stream omitted]';
47
}
48
- $command .= sprintf(' --data %s', escapeshellarg($data));
+ $escapedData = @escapeshellarg($data);
49
+ if (empty($escapedData)) {
50
+ $escapedData = 'We couldn\'t not escape the data properly';
51
+ }
52
+
53
+ $command .= sprintf(' --data %s', $escapedData);
54
55
56
return $command;
0 commit comments