@@ -50,7 +50,7 @@ |
||
| 50 | 50 | try { |
| 51 | 51 | $this->membersService->onUserRemoved($userId); |
| 52 | 52 | } catch (\Exception $e) { |
| 53 | - $this->miscService->log('exception while onUserDeleted ' . $e->getMessage()); |
|
| 53 | + $this->miscService->log('exception while onUserDeleted '.$e->getMessage()); |
|
| 54 | 54 | } |
| 55 | 55 | } |
| 56 | 56 | |
@@ -148,13 +148,13 @@ |
||
| 148 | 148 | } |
| 149 | 149 | |
| 150 | 150 | $info = pathinfo($share->getMountPoint()); |
| 151 | - $filename = $this->get('dirname', $info) . '/' . $this->get('filename', $info); |
|
| 151 | + $filename = $this->get('dirname', $info).'/'.$this->get('filename', $info); |
|
| 152 | 152 | $extension = $this->get('extension', $info); |
| 153 | - $extension = ($extension === '') ? '' : '.' . $extension; |
|
| 153 | + $extension = ($extension === '') ? '' : '.'.$extension; |
|
| 154 | 154 | |
| 155 | 155 | $n = 2; |
| 156 | 156 | while (true) { |
| 157 | - $path = $filename . " ($n)" . $extension; |
|
| 157 | + $path = $filename." ($n)".$extension; |
|
| 158 | 158 | try { |
| 159 | 159 | $fs->get($path); |
| 160 | 160 | } catch (NotFoundException $e) { |
@@ -257,7 +257,7 @@ discard block |
||
| 257 | 257 | * @param $fileName |
| 258 | 258 | * @param string $link |
| 259 | 259 | * @param string $author |
| 260 | - * @param $circleName |
|
| 260 | + * @param string $circleName |
|
| 261 | 261 | * @param string $email |
| 262 | 262 | * |
| 263 | 263 | * @throws Exception |
@@ -294,7 +294,7 @@ discard block |
||
| 294 | 294 | * @param string $circleName |
| 295 | 295 | * @param string $email |
| 296 | 296 | * |
| 297 | - * @param $password |
|
| 297 | + * @param string $password |
|
| 298 | 298 | * |
| 299 | 299 | * @throws NotFoundException |
| 300 | 300 | * @throws Exception |
@@ -371,7 +371,7 @@ discard block |
||
| 371 | 371 | * @param $subject |
| 372 | 372 | * @param $text |
| 373 | 373 | * @param $fileName |
| 374 | - * @param $link |
|
| 374 | + * @param string $link |
|
| 375 | 375 | * @param string $author |
| 376 | 376 | * @param string $circleName |
| 377 | 377 | * |
@@ -105,14 +105,14 @@ discard block |
||
| 105 | 105 | $node = $share->getNode(); |
| 106 | 106 | $filename = $node->getName(); |
| 107 | 107 | } catch (NotFoundException $e) { |
| 108 | - $this->miscService->log('issue while FileShare: ' . $e->getMessage()); |
|
| 108 | + $this->miscService->log('issue while FileShare: '.$e->getMessage()); |
|
| 109 | 109 | |
| 110 | 110 | return; |
| 111 | 111 | } |
| 112 | 112 | |
| 113 | 113 | $event->getData() |
| 114 | 114 | ->s('gs_federated', $share->getToken()) |
| 115 | - ->s('gs_filename', '/' . $filename); |
|
| 115 | + ->s('gs_filename', '/'.$filename); |
|
| 116 | 116 | } |
| 117 | 117 | |
| 118 | 118 | |
@@ -301,7 +301,7 @@ discard block |
||
| 301 | 301 | ); |
| 302 | 302 | } catch (Exception $e) { |
| 303 | 303 | OC::$server->getLogger() |
| 304 | - ->log(1, 'Circles::sharedByMail - mail were not sent: ' . $e->getMessage()); |
|
| 304 | + ->log(1, 'Circles::sharedByMail - mail were not sent: '.$e->getMessage()); |
|
| 305 | 305 | } |
| 306 | 306 | } |
| 307 | 307 | |
@@ -319,8 +319,8 @@ discard block |
||
| 319 | 319 | $message = $this->mailer->createMessage(); |
| 320 | 320 | |
| 321 | 321 | $this->miscService->log( |
| 322 | - "Sending mail to circle '" . $circleName . "': " . $email . ' file: ' . $fileName |
|
| 323 | - . ' - link: ' . $link, 0 |
|
| 322 | + "Sending mail to circle '".$circleName."': ".$email.' file: '.$fileName |
|
| 323 | + . ' - link: '.$link, 0 |
|
| 324 | 324 | ); |
| 325 | 325 | |
| 326 | 326 | $subject = $this->l10n->t('%s shared »%s« with you.', [$author, $fileName]); |
@@ -359,7 +359,7 @@ discard block |
||
| 359 | 359 | |
| 360 | 360 | $message = $this->mailer->createMessage(); |
| 361 | 361 | |
| 362 | - $this->miscService->log("Sending password mail to circle '" . $circleName . "': " . $email, 0); |
|
| 362 | + $this->miscService->log("Sending password mail to circle '".$circleName."': ".$email, 0); |
|
| 363 | 363 | |
| 364 | 364 | $filename = $share->getNode() |
| 365 | 365 | ->getName(); |
@@ -414,7 +414,7 @@ discard block |
||
| 414 | 414 | $message->setFrom([\OCP\Util::getDefaultEmailAddress($instanceName) => $senderName]); |
| 415 | 415 | if ($initiatorEmailAddress !== null) { |
| 416 | 416 | $message->setReplyTo([$initiatorEmailAddress => $initiatorDisplayName]); |
| 417 | - $emailTemplate->addFooter($instanceName . ' - ' . $this->defaults->getSlogan()); |
|
| 417 | + $emailTemplate->addFooter($instanceName.' - '.$this->defaults->getSlogan()); |
|
| 418 | 418 | } else { |
| 419 | 419 | $emailTemplate->addFooter(); |
| 420 | 420 | } |
@@ -449,7 +449,7 @@ discard block |
||
| 449 | 449 | $emailTemplate->addHeader(); |
| 450 | 450 | $emailTemplate->addHeading($subject, false); |
| 451 | 451 | $emailTemplate->addBodyText( |
| 452 | - htmlspecialchars($text) . '<br>' . htmlspecialchars( |
|
| 452 | + htmlspecialchars($text).'<br>'.htmlspecialchars( |
|
| 453 | 453 | $this->l10n->t('Click the button below to open it.') |
| 454 | 454 | ), $text |
| 455 | 455 | ); |
@@ -155,7 +155,7 @@ |
||
| 155 | 155 | $gs = $this->globalScaleService->getGlobalScaleEvent($event); |
| 156 | 156 | $gs->manage($event); |
| 157 | 157 | } catch (Exception $e) { |
| 158 | - $this->miscService->log('issue onNewEvent: ' . json_encode($event) . ' - ' . $e->getMessage()); |
|
| 158 | + $this->miscService->log('issue onNewEvent: '.json_encode($event).' - '.$e->getMessage()); |
|
| 159 | 159 | } |
| 160 | 160 | } |
| 161 | 161 | |
@@ -119,9 +119,9 @@ discard block |
||
| 119 | 119 | $tCards = $tBooks = 0; |
| 120 | 120 | $knownBooks = []; |
| 121 | 121 | foreach ($users as $user) { |
| 122 | - $books = $this->cardDavBackend->getAddressBooksForUser('principals/users/' . $user->getUID()); |
|
| 122 | + $books = $this->cardDavBackend->getAddressBooksForUser('principals/users/'.$user->getUID()); |
|
| 123 | 123 | $output->writeln( |
| 124 | - '- User <info>' . $user->getUID() . '</info> have ' . sizeof($books) . ' address books:' |
|
| 124 | + '- User <info>'.$user->getUID().'</info> have '.sizeof($books).' address books:' |
|
| 125 | 125 | ); |
| 126 | 126 | |
| 127 | 127 | $tBooks += sizeof($books); |
@@ -137,11 +137,11 @@ discard block |
||
| 137 | 137 | |
| 138 | 138 | $shared = ''; |
| 139 | 139 | if ($owner !== $user->getUID()) { |
| 140 | - $shared = ' (shared by <info>' . $owner . '</info>)'; |
|
| 140 | + $shared = ' (shared by <info>'.$owner.'</info>)'; |
|
| 141 | 141 | } |
| 142 | 142 | |
| 143 | 143 | $output->writeln( |
| 144 | - ' <comment>*</comment> book #' . $bookId . $shared . ' contains ' |
|
| 144 | + ' <comment>*</comment> book #'.$bookId.$shared.' contains ' |
|
| 145 | 145 | . sizeof($cards) |
| 146 | 146 | . ' entries' |
| 147 | 147 | ); |
@@ -151,7 +151,7 @@ discard block |
||
| 151 | 151 | } |
| 152 | 152 | |
| 153 | 153 | $output->writeln(''); |
| 154 | - $output->writeln('with a total of ' . $tBooks . ' address books and ' . $tCards . ' contact entries'); |
|
| 154 | + $output->writeln('with a total of '.$tBooks.' address books and '.$tCards.' contact entries'); |
|
| 155 | 155 | } |
| 156 | 156 | |
| 157 | 157 | |
@@ -83,7 +83,7 @@ |
||
| 83 | 83 | |
| 84 | 84 | |
| 85 | 85 | /** |
| 86 | - * @param $search |
|
| 86 | + * @param string $search |
|
| 87 | 87 | * |
| 88 | 88 | * @return array |
| 89 | 89 | */ |
@@ -203,7 +203,7 @@ |
||
| 203 | 203 | $cursor->closeCursor(); |
| 204 | 204 | |
| 205 | 205 | if ($data === false) { |
| 206 | - throw new CircleDoesNotExistException($this->l10n->t('Circle not found ' . $circleUniqueId)); |
|
| 206 | + throw new CircleDoesNotExistException($this->l10n->t('Circle not found '.$circleUniqueId)); |
|
| 207 | 207 | } |
| 208 | 208 | |
| 209 | 209 | $circle = $this->parseCirclesSelectSql($data); |
@@ -92,7 +92,7 @@ |
||
| 92 | 92 | */ |
| 93 | 93 | protected function execute(InputInterface $input, OutputInterface $output): int { |
| 94 | 94 | $instances = $this->globalScaleService->getInstances(true); |
| 95 | - $output->writeln('<info>Instances: </info>' . json_encode($instances)); |
|
| 95 | + $output->writeln('<info>Instances: </info>'.json_encode($instances)); |
|
| 96 | 96 | |
| 97 | 97 | return 0; |
| 98 | 98 | } |
@@ -114,7 +114,7 @@ |
||
| 114 | 114 | * limit the request to the children of a share |
| 115 | 115 | * |
| 116 | 116 | * @param IQueryBuilder $qb |
| 117 | - * @param $userId |
|
| 117 | + * @param string $userId |
|
| 118 | 118 | * @param int $parentId |
| 119 | 119 | */ |
| 120 | 120 | protected function limitToShareChildren(IQueryBuilder $qb, $userId, $parentId = -1) { |
@@ -77,7 +77,7 @@ discard block |
||
| 77 | 77 | $pf = ($qb->getType() === QueryBuilder::SELECT) ? 's.' : ''; |
| 78 | 78 | $qb->andWhere( |
| 79 | 79 | $expr->in( |
| 80 | - $pf . 'share_with', |
|
| 80 | + $pf.'share_with', |
|
| 81 | 81 | $qb->createNamedParameter($circleUniqueIds, IQueryBuilder::PARAM_STR_ARRAY) |
| 82 | 82 | ) |
| 83 | 83 | ); |
@@ -94,7 +94,7 @@ discard block |
||
| 94 | 94 | $expr = $qb->expr(); |
| 95 | 95 | $pf = ($qb->getType() === QueryBuilder::SELECT) ? 's.' : ''; |
| 96 | 96 | |
| 97 | - $qb->andWhere($expr->eq($pf . 'id', $qb->createNamedParameter($shareId))); |
|
| 97 | + $qb->andWhere($expr->eq($pf.'id', $qb->createNamedParameter($shareId))); |
|
| 98 | 98 | } |
| 99 | 99 | |
| 100 | 100 | |
@@ -142,8 +142,8 @@ discard block |
||
| 142 | 142 | |
| 143 | 143 | $qb->andWhere( |
| 144 | 144 | $expr->orX( |
| 145 | - $expr->eq($pf . 'parent', $qb->createNamedParameter($circleId)), |
|
| 146 | - $expr->eq($pf . 'id', $qb->createNamedParameter($circleId)) |
|
| 145 | + $expr->eq($pf.'parent', $qb->createNamedParameter($circleId)), |
|
| 146 | + $expr->eq($pf.'id', $qb->createNamedParameter($circleId)) |
|
| 147 | 147 | ) |
| 148 | 148 | ); |
| 149 | 149 | } |
@@ -165,7 +165,7 @@ discard block |
||
| 165 | 165 | $pf = ($qb->getType() === QueryBuilder::SELECT) ? 's.' : ''; |
| 166 | 166 | $qb->andWhere( |
| 167 | 167 | $expr->in( |
| 168 | - $pf . 'file_source', |
|
| 168 | + $pf.'file_source', |
|
| 169 | 169 | $qb->createNamedParameter($files, IQueryBuilder::PARAM_INT_ARRAY) |
| 170 | 170 | ) |
| 171 | 171 | ); |
@@ -198,12 +198,12 @@ discard block |
||
| 198 | 198 | $pf = ($qb->getType() === QueryBuilder::SELECT) ? 's.' : ''; |
| 199 | 199 | |
| 200 | 200 | if ($reShares === false) { |
| 201 | - $qb->andWhere($expr->eq($pf . 'uid_initiator', $qb->createNamedParameter($userId))); |
|
| 201 | + $qb->andWhere($expr->eq($pf.'uid_initiator', $qb->createNamedParameter($userId))); |
|
| 202 | 202 | } else { |
| 203 | 203 | $qb->andWhere( |
| 204 | 204 | $expr->orX( |
| 205 | - $expr->eq($pf . 'uid_owner', $qb->createNamedParameter($userId)), |
|
| 206 | - $expr->eq($pf . 'uid_initiator', $qb->createNamedParameter($userId)) |
|
| 205 | + $expr->eq($pf.'uid_owner', $qb->createNamedParameter($userId)), |
|
| 206 | + $expr->eq($pf.'uid_initiator', $qb->createNamedParameter($userId)) |
|
| 207 | 207 | ) |
| 208 | 208 | ); |
| 209 | 209 | } |
@@ -298,11 +298,11 @@ discard block |
||
| 298 | 298 | $expr = $qb->expr(); |
| 299 | 299 | $andX = $expr->andX(); |
| 300 | 300 | |
| 301 | - $andX->add($expr->eq($aliasM . '.user_id', $qb->createNamedParameter($userId))); |
|
| 302 | - $andX->add($expr->eq($aliasM . '.circle_id', $aliasC . '.unique_id')); |
|
| 303 | - $andX->add($expr->gte($aliasM . '.level', $qb->createNamedParameter(Member::LEVEL_MEMBER))); |
|
| 304 | - $andX->add($expr->eq($aliasM . '.instance', $qb->createNamedParameter(''))); |
|
| 305 | - $andX->add($expr->eq($aliasM . '.user_type', $qb->createNamedParameter(Member::TYPE_USER))); |
|
| 301 | + $andX->add($expr->eq($aliasM.'.user_id', $qb->createNamedParameter($userId))); |
|
| 302 | + $andX->add($expr->eq($aliasM.'.circle_id', $aliasC.'.unique_id')); |
|
| 303 | + $andX->add($expr->gte($aliasM.'.level', $qb->createNamedParameter(Member::LEVEL_MEMBER))); |
|
| 304 | + $andX->add($expr->eq($aliasM.'.instance', $qb->createNamedParameter(''))); |
|
| 305 | + $andX->add($expr->eq($aliasM.'.user_type', $qb->createNamedParameter(Member::TYPE_USER))); |
|
| 306 | 306 | |
| 307 | 307 | return $andX; |
| 308 | 308 | } |
@@ -330,11 +330,11 @@ discard block |
||
| 330 | 330 | |
| 331 | 331 | $andX = $expr->andX(); |
| 332 | 332 | |
| 333 | - $andX->add($expr->eq($aliasM . '.user_id', 'ncgu.gid')); |
|
| 334 | - $andX->add($expr->eq($aliasM . '.user_type', $qb->createNamedParameter(Member::TYPE_GROUP))); |
|
| 335 | - $andX->add($expr->eq($aliasM . '.instance', $qb->createNamedParameter(''))); |
|
| 336 | - $andX->add($expr->eq($aliasM . '.circle_id', $aliasC . '.unique_id')); |
|
| 337 | - $andX->add($expr->gte($aliasM . '.level', $qb->createNamedParameter(Member::LEVEL_MEMBER))); |
|
| 333 | + $andX->add($expr->eq($aliasM.'.user_id', 'ncgu.gid')); |
|
| 334 | + $andX->add($expr->eq($aliasM.'.user_type', $qb->createNamedParameter(Member::TYPE_GROUP))); |
|
| 335 | + $andX->add($expr->eq($aliasM.'.instance', $qb->createNamedParameter(''))); |
|
| 336 | + $andX->add($expr->eq($aliasM.'.circle_id', $aliasC.'.unique_id')); |
|
| 337 | + $andX->add($expr->gte($aliasM.'.level', $qb->createNamedParameter(Member::LEVEL_MEMBER))); |
|
| 338 | 338 | |
| 339 | 339 | return $andX; |
| 340 | 340 | } |