@@ -68,7 +68,7 @@ |
||
| 68 | 68 | * @return int|float |
| 69 | 69 | * @since 15.0.0 |
| 70 | 70 | */ |
| 71 | - public function getSize(): int|float; |
|
| 71 | + public function getSize(): int | float; |
|
| 72 | 72 | |
| 73 | 73 | /** |
| 74 | 74 | * Get the name of the source file at the time of making this version |
@@ -61,7 +61,7 @@ |
||
| 61 | 61 | * @psalm-suppress ImplementedReturnTypeMismatch \Sabre\DAV\IFile::getSize signature does not support 32bit |
| 62 | 62 | * @return int|float |
| 63 | 63 | */ |
| 64 | - public function getSize(): int|float { |
|
| 64 | + public function getSize(): int | float { |
|
| 65 | 65 | return $this->data->getSize(); |
| 66 | 66 | } |
| 67 | 67 | |
@@ -66,7 +66,7 @@ |
||
| 66 | 66 | } |
| 67 | 67 | } |
| 68 | 68 | |
| 69 | - public function getSize($includeMounts = true): int|float { |
|
| 69 | + public function getSize($includeMounts = true): int | float { |
|
| 70 | 70 | if ($this->fileInfo) { |
| 71 | 71 | return parent::getSize($includeMounts); |
| 72 | 72 | } else { |
@@ -370,18 +370,18 @@ discard block |
||
| 370 | 370 | private function findFileWithExtension($class, $ext) |
| 371 | 371 | { |
| 372 | 372 | // PSR-4 lookup |
| 373 | - $logicalPathPsr4 = strtr($class, '\\', DIRECTORY_SEPARATOR) . $ext; |
|
| 373 | + $logicalPathPsr4 = strtr($class, '\\', DIRECTORY_SEPARATOR).$ext; |
|
| 374 | 374 | |
| 375 | 375 | $first = $class[0]; |
| 376 | 376 | if (isset($this->prefixLengthsPsr4[$first])) { |
| 377 | 377 | $subPath = $class; |
| 378 | 378 | while (false !== $lastPos = strrpos($subPath, '\\')) { |
| 379 | 379 | $subPath = substr($subPath, 0, $lastPos); |
| 380 | - $search = $subPath . '\\'; |
|
| 380 | + $search = $subPath.'\\'; |
|
| 381 | 381 | if (isset($this->prefixDirsPsr4[$search])) { |
| 382 | - $pathEnd = DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $lastPos + 1); |
|
| 382 | + $pathEnd = DIRECTORY_SEPARATOR.substr($logicalPathPsr4, $lastPos + 1); |
|
| 383 | 383 | foreach ($this->prefixDirsPsr4[$search] as $dir) { |
| 384 | - if (file_exists($file = $dir . $pathEnd)) { |
|
| 384 | + if (file_exists($file = $dir.$pathEnd)) { |
|
| 385 | 385 | return $file; |
| 386 | 386 | } |
| 387 | 387 | } |
@@ -391,7 +391,7 @@ discard block |
||
| 391 | 391 | |
| 392 | 392 | // PSR-4 fallback dirs |
| 393 | 393 | foreach ($this->fallbackDirsPsr4 as $dir) { |
| 394 | - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr4)) { |
|
| 394 | + if (file_exists($file = $dir.DIRECTORY_SEPARATOR.$logicalPathPsr4)) { |
|
| 395 | 395 | return $file; |
| 396 | 396 | } |
| 397 | 397 | } |
@@ -403,14 +403,14 @@ discard block |
||
| 403 | 403 | . strtr(substr($logicalPathPsr4, $pos + 1), '_', DIRECTORY_SEPARATOR); |
| 404 | 404 | } else { |
| 405 | 405 | // PEAR-like class name |
| 406 | - $logicalPathPsr0 = strtr($class, '_', DIRECTORY_SEPARATOR) . $ext; |
|
| 406 | + $logicalPathPsr0 = strtr($class, '_', DIRECTORY_SEPARATOR).$ext; |
|
| 407 | 407 | } |
| 408 | 408 | |
| 409 | 409 | if (isset($this->prefixesPsr0[$first])) { |
| 410 | 410 | foreach ($this->prefixesPsr0[$first] as $prefix => $dirs) { |
| 411 | 411 | if (0 === strpos($class, $prefix)) { |
| 412 | 412 | foreach ($dirs as $dir) { |
| 413 | - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) { |
|
| 413 | + if (file_exists($file = $dir.DIRECTORY_SEPARATOR.$logicalPathPsr0)) { |
|
| 414 | 414 | return $file; |
| 415 | 415 | } |
| 416 | 416 | } |
@@ -420,7 +420,7 @@ discard block |
||
| 420 | 420 | |
| 421 | 421 | // PSR-0 fallback dirs |
| 422 | 422 | foreach ($this->fallbackDirsPsr0 as $dir) { |
| 423 | - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) { |
|
| 423 | + if (file_exists($file = $dir.DIRECTORY_SEPARATOR.$logicalPathPsr0)) { |
|
| 424 | 424 | return $file; |
| 425 | 425 | } |
| 426 | 426 | } |
@@ -9,7 +9,7 @@ discard block |
||
| 9 | 9 | public static function loadClassLoader($class) |
| 10 | 10 | { |
| 11 | 11 | if ('Composer\Autoload\ClassLoader' === $class) { |
| 12 | - require __DIR__ . '/ClassLoader.php'; |
|
| 12 | + require __DIR__.'/ClassLoader.php'; |
|
| 13 | 13 | } |
| 14 | 14 | } |
| 15 | 15 | |
@@ -26,7 +26,7 @@ discard block |
||
| 26 | 26 | self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); |
| 27 | 27 | spl_autoload_unregister(array('ComposerAutoloaderInitFiles_External', 'loadClassLoader')); |
| 28 | 28 | |
| 29 | - require __DIR__ . '/autoload_static.php'; |
|
| 29 | + require __DIR__.'/autoload_static.php'; |
|
| 30 | 30 | call_user_func(\Composer\Autoload\ComposerStaticInitFiles_External::getInitializer($loader)); |
| 31 | 31 | |
| 32 | 32 | $loader->setClassMapAuthoritative(true); |
@@ -135,13 +135,13 @@ |
||
| 135 | 135 | $this->progress->finish(); |
| 136 | 136 | $this->output->writeln(''); |
| 137 | 137 | } elseif ($event instanceof RepairStepEvent) { |
| 138 | - $this->output->writeln('<info> - ' . $event->getStepName() . '</info>'); |
|
| 138 | + $this->output->writeln('<info> - '.$event->getStepName().'</info>'); |
|
| 139 | 139 | } elseif ($event instanceof RepairInfoEvent) { |
| 140 | - $this->output->writeln('<info> - ' . $event->getMessage() . '</info>'); |
|
| 140 | + $this->output->writeln('<info> - '.$event->getMessage().'</info>'); |
|
| 141 | 141 | } elseif ($event instanceof RepairWarningEvent) { |
| 142 | - $this->output->writeln('<comment> - WARNING: ' . $event->getMessage() . '</comment>'); |
|
| 142 | + $this->output->writeln('<comment> - WARNING: '.$event->getMessage().'</comment>'); |
|
| 143 | 143 | } elseif ($event instanceof RepairErrorEvent) { |
| 144 | - $this->output->writeln('<error> - ERROR: ' . $event->getMessage() . '</error>'); |
|
| 144 | + $this->output->writeln('<error> - ERROR: '.$event->getMessage().'</error>'); |
|
| 145 | 145 | $this->errored = true; |
| 146 | 146 | } |
| 147 | 147 | } |
@@ -77,15 +77,15 @@ discard block |
||
| 77 | 77 | if (mb_strpos($referenceText, $start) === 0) { |
| 78 | 78 | $parts = parse_url($referenceText); |
| 79 | 79 | parse_str($parts['query'] ?? '', $query); |
| 80 | - $fileId = isset($query['fileid']) ? (int)$query['fileid'] : $fileId; |
|
| 81 | - $fileId = isset($query['openfile']) ? (int)$query['openfile'] : $fileId; |
|
| 80 | + $fileId = isset($query['fileid']) ? (int) $query['fileid'] : $fileId; |
|
| 81 | + $fileId = isset($query['openfile']) ? (int) $query['openfile'] : $fileId; |
|
| 82 | 82 | } |
| 83 | 83 | |
| 84 | 84 | if (mb_strpos($referenceText, $startIndex) === 0) { |
| 85 | 85 | $parts = parse_url($referenceText); |
| 86 | 86 | parse_str($parts['query'] ?? '', $query); |
| 87 | - $fileId = isset($query['fileid']) ? (int)$query['fileid'] : $fileId; |
|
| 88 | - $fileId = isset($query['openfile']) ? (int)$query['openfile'] : $fileId; |
|
| 87 | + $fileId = isset($query['fileid']) ? (int) $query['fileid'] : $fileId; |
|
| 88 | + $fileId = isset($query['openfile']) ? (int) $query['openfile'] : $fileId; |
|
| 89 | 89 | } |
| 90 | 90 | |
| 91 | 91 | if (mb_strpos($referenceText, $this->urlGenerator->getAbsoluteURL('/index.php/f/')) === 0) { |
@@ -96,7 +96,7 @@ discard block |
||
| 96 | 96 | $fileId = str_replace($this->urlGenerator->getAbsoluteURL('/f/'), '', $referenceText); |
| 97 | 97 | } |
| 98 | 98 | |
| 99 | - return $fileId !== null ? (int)$fileId : null; |
|
| 99 | + return $fileId !== null ? (int) $fileId : null; |
|
| 100 | 100 | } |
| 101 | 101 | |
| 102 | 102 | public function resolveReference(string $referenceText): ?IReference { |
@@ -140,7 +140,7 @@ discard block |
||
| 140 | 140 | |
| 141 | 141 | $reference->setTitle($file->getName()); |
| 142 | 142 | $reference->setDescription($file->getMimetype()); |
| 143 | - $reference->setUrl($this->urlGenerator->getAbsoluteURL('/index.php/f/' . $fileId)); |
|
| 143 | + $reference->setUrl($this->urlGenerator->getAbsoluteURL('/index.php/f/'.$fileId)); |
|
| 144 | 144 | if ($this->previewManager->isMimeSupported($file->getMimeType())) { |
| 145 | 145 | $reference->setImageUrl($this->urlGenerator->linkToRouteAbsolute('core.Preview.getPreviewByFileId', ['x' => 1600, 'y' => 630, 'fileId' => $fileId])); |
| 146 | 146 | } else { |
@@ -158,13 +158,13 @@ discard block |
||
| 158 | 158 | 'mtime' => $file->getMTime(), |
| 159 | 159 | 'preview-available' => $this->previewManager->isAvailable($file) |
| 160 | 160 | ]); |
| 161 | - } catch (InvalidPathException|NotFoundException|NotPermittedException|NoUserException $e) { |
|
| 161 | + } catch (InvalidPathException | NotFoundException | NotPermittedException | NoUserException $e) { |
|
| 162 | 162 | throw new NotFoundException(); |
| 163 | 163 | } |
| 164 | 164 | } |
| 165 | 165 | |
| 166 | 166 | public function getCachePrefix(string $referenceId): string { |
| 167 | - return (string)$this->getFilesAppLinkId($referenceId); |
|
| 167 | + return (string) $this->getFilesAppLinkId($referenceId); |
|
| 168 | 168 | } |
| 169 | 169 | |
| 170 | 170 | public function getCacheKey(string $referenceId): ?string { |
@@ -57,7 +57,7 @@ |
||
| 57 | 57 | } |
| 58 | 58 | |
| 59 | 59 | public function getPath() { |
| 60 | - return $this->root->getFileInfo()->getInternalPath() . '/' . $this->partInfo['PartNumber']; |
|
| 60 | + return $this->root->getFileInfo()->getInternalPath().'/'.$this->partInfo['PartNumber']; |
|
| 61 | 61 | } |
| 62 | 62 | |
| 63 | 63 | /** |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | } |
| 67 | 67 | |
| 68 | 68 | public function getPath() { |
| 69 | - return $this->root->getFileInfo()->getInternalPath() . '/.file'; |
|
| 69 | + return $this->root->getFileInfo()->getInternalPath().'/.file'; |
|
| 70 | 70 | } |
| 71 | 71 | |
| 72 | 72 | /** |
@@ -88,7 +88,7 @@ discard block |
||
| 88 | 88 | */ |
| 89 | 89 | public function getSize() { |
| 90 | 90 | $children = $this->root->getChildren(); |
| 91 | - $sizes = array_map(function ($node) { |
|
| 91 | + $sizes = array_map(function($node) { |
|
| 92 | 92 | /** @var IFile $node */ |
| 93 | 93 | return $node->getSize(); |
| 94 | 94 | }, $children); |