Skip to content
This repository was archived by the owner on Nov 10, 2022. It is now read-only.

Commit c239b7d

Browse files
committed
Changed AWS S3 adapter to not override default S3 config if not set
1 parent b967b78 commit c239b7d

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

src/Dmyers/Storage/Adapter/AmazonS3.php

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ public function __construct()
1212
{
1313
$key = $this->config('key');
1414

15+
$region = $this->config('region');
16+
1517
if (empty($key)) {
1618
throw new \RuntimeException('AmazonS3 key config required.');
1719
}
@@ -21,12 +23,6 @@ public function __construct()
2123
if (empty($secret)) {
2224
throw new \RuntimeException('AmazonS3 secret config required.');
2325
}
24-
25-
$region = $this->config('region');
26-
27-
if (empty($region)) {
28-
throw new \RuntimeException('AmazonS3 region config required.');
29-
}
3026

3127
$bucket = $this->config('bucket');
3228

src/config/config.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
'amazons3' => array(
2626
'key' => '',
2727
'secret' => '',
28-
'region' => 'us-east-1',
28+
'region' => '',
2929
'bucket' => '',
3030
'acl' => 'public-read',
3131
),

0 commit comments

Comments
 (0)