@@ -14,7 +14,10 @@ |
||
| 14 | 14 | <input type="submit" id="submitMaxUpload" |
| 15 | 15 | value="<?php p($l->t( 'Save' )); ?>"/> |
| 16 | 16 | <p><em><?php p($l->t('With PHP-FPM it might take 5 minutes for changes to be applied.')); ?></em></p> |
| 17 | - <?php else: ?> |
|
| 18 | - <p><em><?php p($l->t('Missing permissions to edit from here.')); ?></em></p> |
|
| 17 | + <?php else { |
|
| 18 | + : ?> |
|
| 19 | + <p><em><?php p($l->t('Missing permissions to edit from here.')); |
|
| 20 | +} |
|
| 21 | +?></em></p> |
|
| 19 | 22 | <?php endif; ?> |
| 20 | 23 | </div> |
@@ -75,7 +75,7 @@ |
||
| 75 | 75 | } elseif ($file->isMounted()) { |
| 76 | 76 | $icon = \OC::$server->getMimeTypeDetector()->mimeTypeIcon('dir-external'); |
| 77 | 77 | } |
| 78 | - }else{ |
|
| 78 | + } else{ |
|
| 79 | 79 | $icon = \OC::$server->getMimeTypeDetector()->mimeTypeIcon($file->getMimetype()); |
| 80 | 80 | } |
| 81 | 81 | |
@@ -93,8 +93,7 @@ |
||
| 93 | 93 | public function unlink($path) { |
| 94 | 94 | if ($this->is_dir($path)) { |
| 95 | 95 | return $this->rmdir($path); |
| 96 | - } |
|
| 97 | - else { |
|
| 96 | + } else { |
|
| 98 | 97 | $url = $this->constructUrl($path); |
| 99 | 98 | $result = unlink($url); |
| 100 | 99 | clearstatcache(true, $url); |
@@ -62,8 +62,7 @@ |
||
| 62 | 62 | if (substr($root, 0, 1) !== '/'){ |
| 63 | 63 | $root = '/' . $root; |
| 64 | 64 | } |
| 65 | - } |
|
| 66 | - else{ |
|
| 65 | + } else{ |
|
| 67 | 66 | $root = '/'; |
| 68 | 67 | } |
| 69 | 68 | |
@@ -335,7 +335,7 @@ |
||
| 335 | 335 | } |
| 336 | 336 | if($quota === 0) { |
| 337 | 337 | $quota = 'default'; |
| 338 | - }else if($quota === -1) { |
|
| 338 | + } else if($quota === -1) { |
|
| 339 | 339 | $quota = 'none'; |
| 340 | 340 | } else { |
| 341 | 341 | $quota = \OCP\Util::humanFileSize($quota); |
@@ -348,8 +348,9 @@ |
||
| 348 | 348 | $systemMountPoints = $this->getSystemMountPoints(); |
| 349 | 349 | foreach ($systemMountPoints as $mountPoint) { |
| 350 | 350 | $normalizedMountPoint = \OC\Files\Filesystem::normalizePath($mountPoint['mountpoint']) . '/'; |
| 351 | - if (strpos($normalized, $normalizedMountPoint) === 0) |
|
| 352 | - return $targetDir; |
|
| 351 | + if (strpos($normalized, $normalizedMountPoint) === 0) { |
|
| 352 | + return $targetDir; |
|
| 353 | + } |
|
| 353 | 354 | } |
| 354 | 355 | } else if ($trash === false && $this->view->file_exists('/' . $user. '/files/' . $filePath)) { |
| 355 | 356 | return $targetDir; |
@@ -40,8 +40,7 @@ |
||
| 40 | 40 | $list[] = $folder; |
| 41 | 41 | $folder = dirname($folder); |
| 42 | 42 | } |
| 43 | -} |
|
| 44 | -else { |
|
| 43 | +} else { |
|
| 45 | 44 | $deleteAll = false; |
| 46 | 45 | $files = (string)$_POST['files']; |
| 47 | 46 | $list = json_decode($files); |
@@ -119,8 +119,9 @@ |
||
| 119 | 119 | |
| 120 | 120 | // Only handling xml |
| 121 | 121 | $contentType = $request->getHeader('Content-Type'); |
| 122 | - if (strpos($contentType, 'application/xml') === false && strpos($contentType, 'text/xml') === false) |
|
| 123 | - return; |
|
| 122 | + if (strpos($contentType, 'application/xml') === false && strpos($contentType, 'text/xml') === false) { |
|
| 123 | + return; |
|
| 124 | + } |
|
| 124 | 125 | |
| 125 | 126 | // Making sure the node exists |
| 126 | 127 | try { |
@@ -245,7 +245,9 @@ |
||
| 245 | 245 | function httpGet(RequestInterface $request, ResponseInterface $response) { |
| 246 | 246 | // Only handle valid files |
| 247 | 247 | $node = $this->tree->getNodeForPath($request->getPath()); |
| 248 | - if (!($node instanceof IFile)) return; |
|
| 248 | + if (!($node instanceof IFile)) { |
|
| 249 | + return; |
|
| 250 | + } |
|
| 249 | 251 | |
| 250 | 252 | // adds a 'Content-Disposition: attachment' header in case no disposition |
| 251 | 253 | // header has been set before |