@@ -30,8 +30,7 @@ |
||
| 30 | 30 | use OCP\Files\NotFoundException; |
| 31 | 31 | use OCP\Files\NotPermittedException; |
| 32 | 32 | |
| 33 | -interface FolderInterface extends NodeInterface |
|
| 34 | -{ |
|
| 33 | +interface FolderInterface extends NodeInterface { |
|
| 35 | 34 | /** @var bool */ |
| 36 | 35 | const SYNC_SHALLOW = false; |
| 37 | 36 | |
@@ -33,8 +33,7 @@ |
||
| 33 | 33 | use OCP\IDBConnection; |
| 34 | 34 | use OCP\ILogger; |
| 35 | 35 | |
| 36 | -class StorageFolder extends AbstractStorageNode implements FolderInterface |
|
| 37 | -{ |
|
| 36 | +class StorageFolder extends AbstractStorageNode implements FolderInterface { |
|
| 38 | 37 | /** @var OCFolder */ |
| 39 | 38 | protected $node; |
| 40 | 39 | |
@@ -125,6 +125,6 @@ |
||
| 125 | 125 | */ |
| 126 | 126 | public function getPermissions(): int |
| 127 | 127 | { |
| 128 | - return Constants::PERMISSION_READ | Constants::PERMISSION_UPDATE | Constants::PERMISSION_DELETE; |
|
| 128 | + return Constants::PERMISSION_READ|Constants::PERMISSION_UPDATE|Constants::PERMISSION_DELETE; |
|
| 129 | 129 | } |
| 130 | 130 | } |
@@ -28,8 +28,7 @@ |
||
| 28 | 28 | use OCP\Constants; |
| 29 | 29 | use OCP\Files\InvalidPathException; |
| 30 | 30 | |
| 31 | -class MemoryFile extends AbstractNode implements FileInterface |
|
| 32 | -{ |
|
| 31 | +class MemoryFile extends AbstractNode implements FileInterface { |
|
| 33 | 32 | /** @var string */ |
| 34 | 33 | private $path; |
| 35 | 34 | |
@@ -91,7 +91,7 @@ discard block |
||
| 91 | 91 | */ |
| 92 | 92 | public function isReadable(): bool |
| 93 | 93 | { |
| 94 | - return ($this->getPermissions() & Constants::PERMISSION_READ) === Constants::PERMISSION_READ; |
|
| 94 | + return ($this->getPermissions()&Constants::PERMISSION_READ) === Constants::PERMISSION_READ; |
|
| 95 | 95 | } |
| 96 | 96 | |
| 97 | 97 | /** |
@@ -99,7 +99,7 @@ discard block |
||
| 99 | 99 | */ |
| 100 | 100 | public function isUpdateable(): bool |
| 101 | 101 | { |
| 102 | - return ($this->getPermissions() & Constants::PERMISSION_UPDATE) === Constants::PERMISSION_UPDATE; |
|
| 102 | + return ($this->getPermissions()&Constants::PERMISSION_UPDATE) === Constants::PERMISSION_UPDATE; |
|
| 103 | 103 | } |
| 104 | 104 | |
| 105 | 105 | /** |
@@ -107,6 +107,6 @@ discard block |
||
| 107 | 107 | */ |
| 108 | 108 | public function isDeletable(): bool |
| 109 | 109 | { |
| 110 | - return ($this->getPermissions() & Constants::PERMISSION_DELETE) === Constants::PERMISSION_DELETE; |
|
| 110 | + return ($this->getPermissions()&Constants::PERMISSION_DELETE) === Constants::PERMISSION_DELETE; |
|
| 111 | 111 | } |
| 112 | 112 | } |
@@ -26,8 +26,7 @@ |
||
| 26 | 26 | |
| 27 | 27 | use OCP\Constants; |
| 28 | 28 | |
| 29 | -abstract class AbstractNode implements NodeInterface |
|
| 30 | -{ |
|
| 29 | +abstract class AbstractNode implements NodeInterface { |
|
| 31 | 30 | /** |
| 32 | 31 | * {@inheritDoc} |
| 33 | 32 | */ |
@@ -26,8 +26,7 @@ |
||
| 26 | 26 | |
| 27 | 27 | use OCP\Files\File as OCFile; |
| 28 | 28 | |
| 29 | -class StorageFile extends AbstractStorageNode implements FileInterface |
|
| 30 | -{ |
|
| 29 | +class StorageFile extends AbstractStorageNode implements FileInterface { |
|
| 31 | 30 | /** @var OCFile */ |
| 32 | 31 | protected $node; |
| 33 | 32 | |
@@ -69,7 +69,7 @@ discard block |
||
| 69 | 69 | |
| 70 | 70 | if (!@rmdir($this->getLocalPath())) { |
| 71 | 71 | $files = @scandir($this->getLocalPath()); |
| 72 | - if (($files === false) || ($files === [ '.', '..' ])) { |
|
| 72 | + if (($files === false) || ($files === ['.', '..'])) { |
|
| 73 | 73 | throw new GenericFileException(); |
| 74 | 74 | } else { |
| 75 | 75 | throw new NotPermittedException(); |
@@ -203,7 +203,7 @@ discard block |
||
| 203 | 203 | */ |
| 204 | 204 | public function isCreatable(): bool |
| 205 | 205 | { |
| 206 | - return ($this->getPermissions() & Constants::PERMISSION_CREATE) === Constants::PERMISSION_CREATE; |
|
| 206 | + return ($this->getPermissions()&Constants::PERMISSION_CREATE) === Constants::PERMISSION_CREATE; |
|
| 207 | 207 | } |
| 208 | 208 | |
| 209 | 209 | /** |
@@ -31,8 +31,7 @@ |
||
| 31 | 31 | use OCP\Files\NotFoundException; |
| 32 | 32 | use OCP\Files\NotPermittedException; |
| 33 | 33 | |
| 34 | -class LocalFolder extends AbstractLocalNode implements FolderInterface |
|
| 35 | -{ |
|
| 34 | +class LocalFolder extends AbstractLocalNode implements FolderInterface { |
|
| 36 | 35 | /** @var LocalFolder */ |
| 37 | 36 | private $baseFolder; |
| 38 | 37 | |
@@ -29,8 +29,7 @@ |
||
| 29 | 29 | use OCP\Files\NotFoundException; |
| 30 | 30 | use OCP\Files\NotPermittedException; |
| 31 | 31 | |
| 32 | -class LocalFile extends AbstractLocalNode implements FileInterface |
|
| 33 | -{ |
|
| 32 | +class LocalFile extends AbstractLocalNode implements FileInterface { |
|
| 34 | 33 | /** |
| 35 | 34 | * LocalFile constructor. |
| 36 | 35 | * |
@@ -25,8 +25,7 @@ |
||
| 25 | 25 | |
| 26 | 26 | namespace OCA\CMSPico\Exceptions; |
| 27 | 27 | |
| 28 | -class PicoRuntimeException extends \Exception |
|
| 29 | -{ |
|
| 28 | +class PicoRuntimeException extends \Exception { |
|
| 30 | 29 | /** @var \Exception */ |
| 31 | 30 | private $exception; |
| 32 | 31 | |
@@ -25,8 +25,7 @@ |
||
| 25 | 25 | |
| 26 | 26 | namespace OCA\CMSPico\Exceptions; |
| 27 | 27 | |
| 28 | -class AssetNotFoundException extends \Exception |
|
| 29 | -{ |
|
| 28 | +class AssetNotFoundException extends \Exception { |
|
| 30 | 29 | /** |
| 31 | 30 | * AssetNotFoundException constructor. |
| 32 | 31 | * |