@@ -69,10 +69,10 @@ |
||
| 69 | 69 | return $this->url; |
| 70 | 70 | } |
| 71 | 71 | |
| 72 | - $this->url = $this->request->getServerProtocol() . '://';// E.g. http(s) + :// |
|
| 73 | - $this->url .= $this->request->getServerHost();// E.g. localhost |
|
| 74 | - $this->url .= $this->request->getScriptName();// E.g. /nextcloud/index.php |
|
| 75 | - $this->url .= $this->request->getPathInfo();// E.g. /apps/files_texteditor/ajax/loadfile |
|
| 72 | + $this->url = $this->request->getServerProtocol().'://'; // E.g. http(s) + :// |
|
| 73 | + $this->url .= $this->request->getServerHost(); // E.g. localhost |
|
| 74 | + $this->url .= $this->request->getScriptName(); // E.g. /nextcloud/index.php |
|
| 75 | + $this->url .= $this->request->getPathInfo(); // E.g. /apps/files_texteditor/ajax/loadfile |
|
| 76 | 76 | |
| 77 | 77 | return $this->url; // E.g. https://localhost/nextcloud/index.php/apps/files_texteditor/ajax/loadfile |
| 78 | 78 | } |
@@ -17,7 +17,7 @@ discard block |
||
| 17 | 17 | $container = $this->getContainer(); |
| 18 | 18 | $server = $container->getServer(); |
| 19 | 19 | |
| 20 | - $container->registerService(NewUserMailHelper::class, function (SimpleContainer $c) use ($server) { |
|
| 20 | + $container->registerService(NewUserMailHelper::class, function(SimpleContainer $c) use ($server) { |
|
| 21 | 21 | return new NewUserMailHelper( |
| 22 | 22 | $server->query(Defaults::class), |
| 23 | 23 | $server->getURLGenerator(), |
@@ -30,7 +30,7 @@ discard block |
||
| 30 | 30 | Util::getDefaultEmailAddress('no-reply') |
| 31 | 31 | ); |
| 32 | 32 | }); |
| 33 | - $container->registerService('ProvisioningApiMiddleware', function (SimpleContainer $c) use ($server) { |
|
| 33 | + $container->registerService('ProvisioningApiMiddleware', function(SimpleContainer $c) use ($server) { |
|
| 34 | 34 | $user = $server->getUserManager()->get($c['UserId']); |
| 35 | 35 | $isAdmin = $user !== null ? $server->getGroupManager()->isAdmin($user->getUID()) : false; |
| 36 | 36 | $isSubAdmin = $user !== null ? $server->getGroupManager()->getSubAdmin()->isSubAdmin($user) : false; |
@@ -89,7 +89,7 @@ discard block |
||
| 89 | 89 | } else { |
| 90 | 90 | $p = new ProgressBar($output); |
| 91 | 91 | $p->start(); |
| 92 | - $this->userManager->callForSeenUsers(function (IUser $user) use ($p) { |
|
| 92 | + $this->userManager->callForSeenUsers(function(IUser $user) use ($p) { |
|
| 93 | 93 | $p->advance(); |
| 94 | 94 | $this->expireVersionsForUser($user); |
| 95 | 95 | }); |
@@ -116,7 +116,7 @@ discard block |
||
| 116 | 116 | \OC_Util::setupFS($user); |
| 117 | 117 | |
| 118 | 118 | // Check if this user has a version directory |
| 119 | - $view = new \OC\Files\View('/' . $user); |
|
| 119 | + $view = new \OC\Files\View('/'.$user); |
|
| 120 | 120 | if (!$view->is_dir('/files_versions')) { |
| 121 | 121 | return false; |
| 122 | 122 | } |
@@ -105,8 +105,8 @@ |
||
| 105 | 105 | protected function deleteVersions($user) { |
| 106 | 106 | \OC_Util::tearDownFS(); |
| 107 | 107 | \OC_Util::setupFS($user); |
| 108 | - if ($this->rootFolder->nodeExists('/' . $user . '/files_versions')) { |
|
| 109 | - $this->rootFolder->get('/' . $user . '/files_versions')->delete(); |
|
| 108 | + if ($this->rootFolder->nodeExists('/'.$user.'/files_versions')) { |
|
| 109 | + $this->rootFolder->get('/'.$user.'/files_versions')->delete(); |
|
| 110 | 110 | } |
| 111 | 111 | } |
| 112 | 112 | } |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | return; |
| 67 | 67 | } |
| 68 | 68 | |
| 69 | - $this->userManager->callForSeenUsers(function (IUser $user) { |
|
| 69 | + $this->userManager->callForSeenUsers(function(IUser $user) { |
|
| 70 | 70 | $uid = $user->getUID(); |
| 71 | 71 | if (!$this->setupFS($uid)) { |
| 72 | 72 | return; |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | \OC_Util::setupFS($user); |
| 86 | 86 | |
| 87 | 87 | // Check if this user has a versions directory |
| 88 | - $view = new \OC\Files\View('/' . $user); |
|
| 88 | + $view = new \OC\Files\View('/'.$user); |
|
| 89 | 89 | if (!$view->is_dir('/files_versions')) { |
| 90 | 90 | return false; |
| 91 | 91 | } |
@@ -99,7 +99,7 @@ |
||
| 99 | 99 | $this->checker->writeCoreSignature($x509, $rsa, $path); |
| 100 | 100 | $output->writeln('Successfully signed "core"'); |
| 101 | 101 | } catch (\Exception $e) { |
| 102 | - $output->writeln('Error: ' . $e->getMessage()); |
|
| 102 | + $output->writeln('Error: '.$e->getMessage()); |
|
| 103 | 103 | return 1; |
| 104 | 104 | } |
| 105 | 105 | return 0; |
@@ -51,7 +51,7 @@ |
||
| 51 | 51 | */ |
| 52 | 52 | public function completeArgumentValues($argumentName, CompletionContext $context) { |
| 53 | 53 | if ($argumentName === 'uid') { |
| 54 | - return array_map(function (IUser $user) { |
|
| 54 | + return array_map(function(IUser $user) { |
|
| 55 | 55 | return $user->getUID(); |
| 56 | 56 | }, $this->userManager->search($context->getCurrentWord(), 100)); |
| 57 | 57 | } |
@@ -67,11 +67,11 @@ |
||
| 67 | 67 | */ |
| 68 | 68 | protected function writeModuleList(InputInterface $input, OutputInterface $output, $items) { |
| 69 | 69 | if ($input->getOption('output') === self::OUTPUT_FORMAT_PLAIN) { |
| 70 | - array_walk($items, function (&$item) { |
|
| 70 | + array_walk($items, function(&$item) { |
|
| 71 | 71 | if (!$item['default']) { |
| 72 | 72 | $item = $item['displayName']; |
| 73 | 73 | } else { |
| 74 | - $item = $item['displayName'] . ' [default*]'; |
|
| 74 | + $item = $item['displayName'].' [default*]'; |
|
| 75 | 75 | } |
| 76 | 76 | }); |
| 77 | 77 | } |
@@ -147,7 +147,7 @@ discard block |
||
| 147 | 147 | public function castColumn($column, $type) { |
| 148 | 148 | if ($type === IQueryBuilder::PARAM_STR) { |
| 149 | 149 | $column = $this->helper->quoteColumnName($column); |
| 150 | - return new QueryFunction('to_char(' . $column . ')'); |
|
| 150 | + return new QueryFunction('to_char('.$column.')'); |
|
| 151 | 151 | } |
| 152 | 152 | |
| 153 | 153 | return parent::castColumn($column, $type); |
@@ -157,7 +157,7 @@ discard block |
||
| 157 | 157 | * @inheritdoc |
| 158 | 158 | */ |
| 159 | 159 | public function like($x, $y, $type = null) { |
| 160 | - return parent::like($x, $y, $type) . " ESCAPE '\\'"; |
|
| 160 | + return parent::like($x, $y, $type)." ESCAPE '\\'"; |
|
| 161 | 161 | } |
| 162 | 162 | |
| 163 | 163 | /** |
@@ -166,6 +166,6 @@ discard block |
||
| 166 | 166 | public function iLike($x, $y, $type = null) { |
| 167 | 167 | $x = $this->helper->quoteColumnName($x); |
| 168 | 168 | $y = $this->helper->quoteColumnName($y); |
| 169 | - return new QueryFunction('REGEXP_LIKE(' . $x . ', \'^\' || REPLACE(REPLACE(' . $y . ', \'%\', \'.*\'), \'_\', \'.\') || \'$\', \'i\')'); |
|
| 169 | + return new QueryFunction('REGEXP_LIKE('.$x.', \'^\' || REPLACE(REPLACE('.$y.', \'%\', \'.*\'), \'_\', \'.\') || \'$\', \'i\')'); |
|
| 170 | 170 | } |
| 171 | 171 | } |