@@ -41,44 +41,44 @@ |
||
| 41 | 41 | $is_optional = $parameter->isFlagSet(DefinitionParameter::FLAG_OPTIONAL); |
| 42 | 42 | |
| 43 | 43 | switch ($parameter->getType()) { |
| 44 | - case DefinitionParameter::VALUE_PASSWORD: ?> |
|
| 45 | - <?php if ($is_optional) { $classes[] = 'optional'; } ?> |
|
| 46 | - <input type="password" |
|
| 44 | + case DefinitionParameter::VALUE_PASSWORD: ?> |
|
| 45 | + <?php if ($is_optional) { $classes[] = 'optional'; } ?> |
|
| 46 | + <input type="password" |
|
| 47 | 47 | <?php if (!empty($classes)): ?> class="<?php p(implode(' ', $classes)); ?>"<?php endif; ?> |
| 48 | - data-parameter="<?php p($parameter->getName()); ?>" |
|
| 48 | + data-parameter="<?php p($parameter->getName()); ?>" |
|
| 49 | 49 | value="<?php p($value); ?>" |
| 50 | 50 | placeholder="<?php p($placeholder); ?>" |
| 51 | 51 | /> |
| 52 | 52 | <?php |
| 53 | - break; |
|
| 54 | - case DefinitionParameter::VALUE_BOOLEAN: ?> |
|
| 55 | - <?php $checkboxId = uniqid("checkbox_"); ?> |
|
| 53 | + break; |
|
| 54 | + case DefinitionParameter::VALUE_BOOLEAN: ?> |
|
| 55 | + <?php $checkboxId = uniqid("checkbox_"); ?> |
|
| 56 | 56 | <div> |
| 57 | 57 | <label> |
| 58 | 58 | <input type="checkbox" |
| 59 | 59 | id="<?php p($checkboxId); ?>" |
| 60 | 60 | <?php if (!empty($classes)): ?> class="checkbox <?php p(implode(' ', $classes)); ?>"<?php endif; ?> |
| 61 | - data-parameter="<?php p($parameter->getName()); ?>" |
|
| 61 | + data-parameter="<?php p($parameter->getName()); ?>" |
|
| 62 | 62 | <?php if ($value === true): ?> checked="checked"<?php endif; ?> |
| 63 | - /> |
|
| 63 | + /> |
|
| 64 | 64 | <?php p($placeholder); ?> |
| 65 | 65 | </label> |
| 66 | 66 | </div> |
| 67 | 67 | <?php |
| 68 | - break; |
|
| 69 | - case DefinitionParameter::VALUE_HIDDEN: ?> |
|
| 70 | - <input type="hidden" |
|
| 68 | + break; |
|
| 69 | + case DefinitionParameter::VALUE_HIDDEN: ?> |
|
| 70 | + <input type="hidden" |
|
| 71 | 71 | <?php if (!empty($classes)): ?> class="<?php p(implode(' ', $classes)); ?>"<?php endif; ?> |
| 72 | - data-parameter="<?php p($parameter->getName()); ?>" |
|
| 72 | + data-parameter="<?php p($parameter->getName()); ?>" |
|
| 73 | 73 | value="<?php p($value); ?>" |
| 74 | 74 | /> |
| 75 | 75 | <?php |
| 76 | - break; |
|
| 77 | - default: ?> |
|
| 78 | - <?php if ($is_optional) { $classes[] = 'optional'; } ?> |
|
| 79 | - <input type="text" |
|
| 76 | + break; |
|
| 77 | + default: ?> |
|
| 78 | + <?php if ($is_optional) { $classes[] = 'optional'; } ?> |
|
| 79 | + <input type="text" |
|
| 80 | 80 | <?php if (!empty($classes)): ?> class="<?php p(implode(' ', $classes)); ?>"<?php endif; ?> |
| 81 | - data-parameter="<?php p($parameter->getName()); ?>" |
|
| 81 | + data-parameter="<?php p($parameter->getName()); ?>" |
|
| 82 | 82 | value="<?php p($value); ?>" |
| 83 | 83 | placeholder="<?php p($placeholder); ?>" |
| 84 | 84 | /> |
@@ -62,18 +62,18 @@ |
||
| 62 | 62 | $placeholder = substr($placeholder, 1); |
| 63 | 63 | } |
| 64 | 64 | switch ($placeholder[0]) { |
| 65 | - case '!': |
|
| 66 | - $type = DefinitionParameter::VALUE_BOOLEAN; |
|
| 67 | - $placeholder = substr($placeholder, 1); |
|
| 68 | - break; |
|
| 69 | - case '*': |
|
| 70 | - $type = DefinitionParameter::VALUE_PASSWORD; |
|
| 71 | - $placeholder = substr($placeholder, 1); |
|
| 72 | - break; |
|
| 73 | - case '#': |
|
| 74 | - $type = DefinitionParameter::VALUE_HIDDEN; |
|
| 75 | - $placeholder = substr($placeholder, 1); |
|
| 76 | - break; |
|
| 65 | + case '!': |
|
| 66 | + $type = DefinitionParameter::VALUE_BOOLEAN; |
|
| 67 | + $placeholder = substr($placeholder, 1); |
|
| 68 | + break; |
|
| 69 | + case '*': |
|
| 70 | + $type = DefinitionParameter::VALUE_PASSWORD; |
|
| 71 | + $placeholder = substr($placeholder, 1); |
|
| 72 | + break; |
|
| 73 | + case '#': |
|
| 74 | + $type = DefinitionParameter::VALUE_HIDDEN; |
|
| 75 | + $placeholder = substr($placeholder, 1); |
|
| 76 | + break; |
|
| 77 | 77 | } |
| 78 | 78 | $this->addParameter((new DefinitionParameter($name, $placeholder)) |
| 79 | 79 | ->setType($type) |
@@ -140,16 +140,16 @@ discard block |
||
| 140 | 140 | protected function convertLevelString($level) { |
| 141 | 141 | $level = strtolower($level); |
| 142 | 142 | switch ($level) { |
| 143 | - case 'debug': |
|
| 144 | - return 0; |
|
| 145 | - case 'info': |
|
| 146 | - return 1; |
|
| 147 | - case 'warning': |
|
| 148 | - case 'warn': |
|
| 149 | - return 2; |
|
| 150 | - case 'error': |
|
| 151 | - case 'err': |
|
| 152 | - return 3; |
|
| 143 | + case 'debug': |
|
| 144 | + return 0; |
|
| 145 | + case 'info': |
|
| 146 | + return 1; |
|
| 147 | + case 'warning': |
|
| 148 | + case 'warn': |
|
| 149 | + return 2; |
|
| 150 | + case 'error': |
|
| 151 | + case 'err': |
|
| 152 | + return 3; |
|
| 153 | 153 | } |
| 154 | 154 | throw new \InvalidArgumentException('Invalid log level string'); |
| 155 | 155 | } |
@@ -161,14 +161,14 @@ discard block |
||
| 161 | 161 | */ |
| 162 | 162 | protected function convertLevelNumber($levelNum) { |
| 163 | 163 | switch ($levelNum) { |
| 164 | - case 0: |
|
| 165 | - return 'Debug'; |
|
| 166 | - case 1: |
|
| 167 | - return 'Info'; |
|
| 168 | - case 2: |
|
| 169 | - return 'Warning'; |
|
| 170 | - case 3: |
|
| 171 | - return 'Error'; |
|
| 164 | + case 0: |
|
| 165 | + return 'Debug'; |
|
| 166 | + case 1: |
|
| 167 | + return 'Info'; |
|
| 168 | + case 2: |
|
| 169 | + return 'Warning'; |
|
| 170 | + case 3: |
|
| 171 | + return 'Error'; |
|
| 172 | 172 | } |
| 173 | 173 | throw new \InvalidArgumentException('Invalid log level number'); |
| 174 | 174 | } |
@@ -21,7 +21,6 @@ |
||
| 21 | 21 | |
| 22 | 22 | namespace OCA\Files_External\Lib\Backend; |
| 23 | 23 | |
| 24 | -use OCA\Files_External\Lib\Storage\InvalidStorage; |
|
| 25 | 24 | use OCA\Files_External\Lib\StorageConfig; |
| 26 | 25 | use OCP\Files\StorageNotAvailableException; |
| 27 | 26 | use OCP\IUser; |
@@ -29,7 +29,6 @@ |
||
| 29 | 29 | use OC\Files\Storage\Wrapper\Availability; |
| 30 | 30 | use OCA\Files_External\Migration\StorageMigrator; |
| 31 | 31 | use OCP\Files\Storage; |
| 32 | -use OC\Files\Mount\MountPoint; |
|
| 33 | 32 | use OCP\Files\Storage\IStorageFactory; |
| 34 | 33 | use OCA\Files_External\Lib\PersonalMount; |
| 35 | 34 | use OCP\Files\Config\IMountProvider; |
@@ -116,7 +116,6 @@ |
||
| 116 | 116 | use OC\Template\SCSSCacher; |
| 117 | 117 | use OCA\Theming\ImageManager; |
| 118 | 118 | use OCA\Theming\ThemingDefaults; |
| 119 | - |
|
| 120 | 119 | use OCP\App\IAppManager; |
| 121 | 120 | use OCP\AppFramework\Utility\ITimeFactory; |
| 122 | 121 | use OCP\Collaboration\AutoComplete\IManager; |
@@ -26,7 +26,6 @@ |
||
| 26 | 26 | |
| 27 | 27 | use OCA\Files_External\Service\BackendService; |
| 28 | 28 | use OCA\Files_External\Service\DBConfigService; |
| 29 | -use OCA\Files_External\Service\GlobalLegacyStoragesService; |
|
| 30 | 29 | use OCA\Files_External\Service\LegacyStoragesService; |
| 31 | 30 | use OCA\Files_External\Service\StoragesService; |
| 32 | 31 | use OCA\Files_External\Service\UserLegacyStoragesService; |
@@ -42,7 +42,6 @@ |
||
| 42 | 42 | use OCP\AppFramework\Http\DataResponse; |
| 43 | 43 | use OCP\AppFramework\Http\NotFoundResponse; |
| 44 | 44 | use OCP\AppFramework\Utility\ITimeFactory; |
| 45 | -use OCP\Files\File; |
|
| 46 | 45 | use OCP\Files\IAppData; |
| 47 | 46 | use OCP\Files\NotFoundException; |
| 48 | 47 | use OCP\Files\NotPermittedException; |
@@ -27,10 +27,6 @@ |
||
| 27 | 27 | namespace OC\Settings\Admin; |
| 28 | 28 | |
| 29 | 29 | use Doctrine\DBAL\Connection; |
| 30 | -use Doctrine\DBAL\DBALException; |
|
| 31 | -use Doctrine\DBAL\Platforms\SqlitePlatform; |
|
| 32 | -use OC\Lock\DBLockingProvider; |
|
| 33 | -use OC\Lock\NoopLockingProvider; |
|
| 34 | 30 | use OCP\AppFramework\Http\TemplateResponse; |
| 35 | 31 | use OCP\IConfig; |
| 36 | 32 | use OCP\IDBConnection; |