Test Setup Failed
Push — master ( 44c35f...eb4f85 )
by Carlos
05:12
created
src/QiniuAdapter.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -182,7 +182,7 @@  discard block
 block discarded – undo
182 182
         }
183 183
     }
184 184
 
185
-    protected function getMetadata($path): FileAttributes|array
185
+    protected function getMetadata($path): FileAttributes | array
186 186
     {
187 187
         $result = $this->getBucketManager()->stat($this->bucket, $path);
188 188
         $result[0]['key'] = $path;
@@ -193,13 +193,13 @@  discard block
 block discarded – undo
193 193
     public function getUrl(string $path): string
194 194
     {
195 195
         $segments = $this->parseUrl($path);
196
-        $query = empty($segments['query']) ? '' : '?' . $segments['query'];
196
+        $query = empty($segments['query']) ? '' : '?'.$segments['query'];
197 197
 
198
-        return $this->normalizeHost($this->domain) . ltrim(implode('/', array_map('rawurlencode', explode('/', $segments['path']))), '/') . $query;
198
+        return $this->normalizeHost($this->domain).ltrim(implode('/', array_map('rawurlencode', explode('/', $segments['path']))), '/').$query;
199 199
     }
200 200
 
201 201
 
202
-    public function fetch(string $path, string $url): bool|array
202
+    public function fetch(string $path, string $url): bool | array
203 203
     {
204 204
         [$response, $error] = $this->getBucketManager()->fetch($url, $this->bucket, $path);
205 205
 
@@ -213,7 +213,7 @@  discard block
 block discarded – undo
213 213
     /**
214 214
      * For laravel FilesystemAdapter.
215 215
      */
216
-    public function getTemporaryUrl($path, int|string|\DateTimeInterface $expiration): string
216
+    public function getTemporaryUrl($path, int | string | \DateTimeInterface $expiration): string
217 217
     {
218 218
         if ($expiration instanceof \DateTimeInterface) {
219 219
             $expiration = $expiration->getTimestamp();
@@ -231,7 +231,7 @@  discard block
 block discarded – undo
231 231
         return $this->getAuthManager()->privateDownloadUrl($this->getUrl($path), $expires);
232 232
     }
233 233
 
234
-    public function refresh(string|array $path): array
234
+    public function refresh(string | array $path): array
235 235
     {
236 236
         // 将 $path 变成完整的 url
237 237
         $urls = array_map([$this, 'getUrl'], (array) $path);
@@ -315,7 +315,7 @@  discard block
 block discarded – undo
315 315
             $domain = "http://{$domain}";
316 316
         }
317 317
 
318
-        return rtrim($domain, '/') . '/';
318
+        return rtrim($domain, '/').'/';
319 319
     }
320 320
 
321 321
     protected static function parseUrl($url): array
Please login to merge, or discard this patch.