Better error message for invalid bucket names
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
This commit is contained in:
parent
576d31d48d
commit
8b763ea0f7
1 changed files with 2 additions and 2 deletions
|
@ -90,8 +90,8 @@ trait S3ConnectionTrait {
|
|||
}
|
||||
$this->connection = new S3Client($options);
|
||||
|
||||
if (!S3Client::isBucketDnsCompatible($this->bucket)) {
|
||||
throw new \Exception("The configured bucket name is invalid.");
|
||||
if (!$this->connection->isBucketDnsCompatible($this->bucket)) {
|
||||
throw new \Exception("The configured bucket name is invalid: " . $this->bucket);
|
||||
}
|
||||
|
||||
if (!$this->connection->doesBucketExist($this->bucket)) {
|
||||
|
|
Loading…
Reference in a new issue