@@ 74-78 (lines=5) @@ | ||
71 | throw new Exception('SoftLayer SDK not loaded: use composer to install "softlayer/objectstorage"'); |
|
72 | } |
|
73 | // check for mandatory options |
|
74 | foreach (['user', 'secret', 'container', 'host', 'path'] as $option) { |
|
75 | if (!Arr::isSetAndNotEmptyString($config, $option)) { |
|
76 | throw new Exception('SoftLayer ' . $option . ' is mandatory'); |
|
77 | } |
|
78 | } |
|
79 | ||
80 | $this->user = $config['user']; |
|
81 | $this->secret = $config['secret']; |
@@ 107-111 (lines=5) @@ | ||
104 | } |
|
105 | ||
106 | // check for mandatory options |
|
107 | foreach (['key', 'secret', 'bucket', 'region', 'path'] as $option) { |
|
108 | if (!Arr::isSetAndNotEmptyString($config, $option)) { |
|
109 | throw new Exception('AWS S3 ' . $option . ' is mandatory'); |
|
110 | } |
|
111 | } |
|
112 | ||
113 | $this->key = $config['key']; |
|
114 | $this->secret = $config['secret']; |