classes/Cloud/Storage/Driver/S3/S3Storage.php
protected function getClient($errorCollector = null) {
		if(!$this->enabled()) {
            if ($errorCollector) {
                $errorCollector->addError("Account ID, account secret and/or the bucket are incorrect or missing.");
            }

			return null;
		}

		$s3 = $this->getS3Client(false, $errorCollector);
		if(!$s3) {
			Logger::info('Could not create regular client, creating multi-region client instead.');

            if ($errorCollector) {
                $errorCollector->addError("Could not create regular client, creating multi-region client instead.");
            }

            $s3 = $this->getS3MultiRegionClient();

            if (!$s3 && $errorCollector) {
                $errorCollector->addError("Could not create regular client, creating multi-region client instead.");
            }
		}

		return $s3;
	}
protected function getClient($errorCollector = null) {
		if(!$this->enabled()) {
            if ($errorCollector) {
                $errorCollector->addError("Account ID, account secret and/or the bucket are incorrect or missing.");
            }

			return null;
		}

		$s3 = $this->getS3Client(false, $errorCollector);
		if(!$s3) {
			Logger::info('Could not create regular client, creating multi-region client instead.');

            if ($errorCollector) {
                $errorCollector->addError("Could not create regular client, creating multi-region client instead.");
            }

            $s3 = $this->getS3MultiRegionClient();

            if (!$s3 && $errorCollector) {
                $errorCollector->addError("Could not create regular client, creating multi-region client instead.");
            }
		}

		return $s3;
	}
protected function getClient ( $ errorCollector = null ) { if ( ! $ this -> enabled ( ) ) { if ( $ errorCollector ) { $ errorCollector -> addError ( "Account ID, account secret and/or the bucket are incorrect or missing." ) ; } return null ; } $ s3 = $ this -> getS3Client ( false , $ errorCollector ) ; if ( ! $ s3 ) { Logger :: info ( 'Could not create regular client, creating multi-region client instead.' ) ; if ( $ errorCollector ) { $ errorCollector -> addError ( "Could not create regular client, creating multi-region client instead." ) ; } $ s3 = $ this -> getS3MultiRegionClient ( ) ; if ( ! $ s3 && $ errorCollector ) { $ errorCollector -> addError ( "Could not create regular client, creating multi-region client instead." ) ; } } return $ s3 ; }
Gets the S3Client
@param ErrorCollector|null $errorCollector
@return S3Client|S3MultiRegionClient|null
Gets the S3Client