| Conditions | 2 |
| Paths | 2 |
| Total Lines | 13 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 24 | public static function createS3Client(string $version, string $region, ?string $endpoint, string $key, string $secret): S3Client |
||
| 25 | { |
||
| 26 | $options = [ |
||
| 27 | 'region' => $region, |
||
| 28 | 'version' => $version, |
||
| 29 | 'endpoint' => !empty($endpoint) ? $endpoint : null, |
||
| 30 | 'credentials' => new Credentials($key, $secret), |
||
| 31 | ]; |
||
| 32 | |||
| 33 | $s3Client = new S3Client($options); |
||
| 34 | |||
| 35 | return $s3Client; |
||
| 36 | } |
||
| 37 | } |
||
| 38 |