PluginProbe
Media Cloud Sync / 1.4.2
Media Cloud Sync v1.4.2
1.4.2 1.4.1 1.4.0 1.3.12 1.3.11 1.3.10 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.1.0 1.1.1 1.2.0 1.2.10 1.2.11 1.2.12 1.2.13 1.2.2 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 All 36 releases
← All changes | includes/sdk/s3/Aws/PresignUrlMiddleware.php +2 -2 1.2.13 → 1.4.2 View file →
@@ -41,9 +41,9 @@
41 41 $f = new PresignUrlMiddleware($options, $endpointProvider, $client, $handler);
42 42 return $f;
43 43 };
44 44 }
45 - public function __invoke(CommandInterface $cmd, RequestInterface $request = null)
45 + public function __invoke(CommandInterface $cmd, ?RequestInterface $request = null)
46 46 {
47 47 if (\in_array($cmd->getName(), $this->commandPool) && !isset($cmd['__skip' . $cmd->getName()])) {
48 48 $cmd['DestinationRegion'] = $this->client->getRegion();
49 49 if (!empty($cmd['SourceRegion']) && !empty($cmd[$this->presignParam])) {
@@ -81,9 +81,9 @@
81 81 $paramsToAdd = \false;
82 82 if (!empty($this->extraQueryParams[$cmdName])) {
83 83 foreach ($this->extraQueryParams[$cmdName] as $param) {
84 84 if (!\strpos($currentQueryParams, $param)) {
85 - $paramsToAdd = "&{$param}={$cmd[$param]}";
85 + $paramsToAdd = "&{$param}=" . \urlencode($cmd[$param]);
86 86 }
87 87 }
88 88 }
89 89 return (string) $signer->presign(SignatureV4::convertPostToGet($request, $paramsToAdd ?: ""), $client->getCredentials()->wait(), '+1 hour')->getUri();