@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | |
30 | 30 | class Manager implements IManager { |
31 | 31 | /** @var string[] */ |
32 | - protected $sorters =[]; |
|
32 | + protected $sorters = []; |
|
33 | 33 | |
34 | 34 | /** @var ISorter[] */ |
35 | 35 | protected $sorterInstances = []; |
@@ -42,8 +42,8 @@ discard block |
||
42 | 42 | |
43 | 43 | public function runSorters(array $sorters, array &$sortArray, array $context) { |
44 | 44 | $sorterInstances = $this->getSorters(); |
45 | - while($sorter = array_shift($sorters)) { |
|
46 | - if(isset($sorterInstances[$sorter])) { |
|
45 | + while ($sorter = array_shift($sorters)) { |
|
46 | + if (isset($sorterInstances[$sorter])) { |
|
47 | 47 | $sorterInstances[$sorter]->sort($sortArray, $context); |
48 | 48 | } else { |
49 | 49 | $this->c->getLogger()->warning('No sorter for ID "{id}", skipping', [ |
@@ -58,17 +58,17 @@ discard block |
||
58 | 58 | } |
59 | 59 | |
60 | 60 | protected function getSorters() { |
61 | - if(count($this->sorterInstances) === 0) { |
|
61 | + if (count($this->sorterInstances) === 0) { |
|
62 | 62 | foreach ($this->sorters as $sorter) { |
63 | 63 | /** @var ISorter $instance */ |
64 | 64 | $instance = $this->c->resolve($sorter); |
65 | - if(!$instance instanceof ISorter) { |
|
65 | + if (!$instance instanceof ISorter) { |
|
66 | 66 | $this->c->getLogger()->notice('Skipping sorter which is not an instance of ISorter. Class name: {class}', |
67 | 67 | ['app' => 'core', 'class' => $sorter]); |
68 | 68 | continue; |
69 | 69 | } |
70 | 70 | $sorterId = trim($instance->getId()); |
71 | - if(trim($sorterId) === '') { |
|
71 | + if (trim($sorterId) === '') { |
|
72 | 72 | $this->c->getLogger()->notice('Skipping sorter with empty ID. Class name: {class}', |
73 | 73 | ['app' => 'core', 'class' => $sorter]); |
74 | 74 | continue; |
@@ -26,7 +26,7 @@ |
||
26 | 26 | <h2 class="inlineblock"><?php p($_['heading']); ?></h2> |
27 | 27 | <?php if (!empty($_['docs'])): ?> |
28 | 28 | <a target="_blank" rel="noreferrer noopener" class="icon-info svg" |
29 | - title="<?php p($l->t('Open documentation'));?>" |
|
29 | + title="<?php p($l->t('Open documentation')); ?>" |
|
30 | 30 | href="<?php p(link_to_docs($_['docs'])); ?>"> |
31 | 31 | </a> |
32 | 32 | <?php endif; ?> |
@@ -1,11 +1,11 @@ |
||
1 | 1 | <div class="ldapSettingControls"> |
2 | 2 | <button type="button" class="ldap_action_test_connection" name="ldap_action_test_connection"> |
3 | - <?php p($l->t('Test Configuration'));?> |
|
3 | + <?php p($l->t('Test Configuration')); ?> |
|
4 | 4 | </button> |
5 | 5 | <a href="<?php p(link_to_docs('admin-ldap')); ?>" |
6 | 6 | target="_blank" rel="noreferrer noopener"> |
7 | 7 | <img src="<?php print_unescaped(image_path('', 'actions/info.svg')); ?>" |
8 | 8 | style="height:1.75ex" /> |
9 | - <?php p($l->t('Help'));?> |
|
9 | + <?php p($l->t('Help')); ?> |
|
10 | 10 | </a> |
11 | 11 | </div> |
@@ -55,15 +55,15 @@ |
||
55 | 55 | public function getMountsForUser(IUser $user, IStorageFactory $loader) { |
56 | 56 | $cacheBaseDir = $this->config->getSystemValue('cache_path', ''); |
57 | 57 | if ($cacheBaseDir !== '') { |
58 | - $cacheDir = rtrim($cacheBaseDir, '/') . '/' . $user->getUID(); |
|
58 | + $cacheDir = rtrim($cacheBaseDir, '/').'/'.$user->getUID(); |
|
59 | 59 | if (!file_exists($cacheDir)) { |
60 | 60 | mkdir($cacheDir, 0770, true); |
61 | - mkdir($cacheDir . '/uploads', 0770, true); |
|
61 | + mkdir($cacheDir.'/uploads', 0770, true); |
|
62 | 62 | } |
63 | 63 | |
64 | 64 | return [ |
65 | - new MountPoint('\OC\Files\Storage\Local', '/' . $user->getUID() . '/cache', ['datadir' => $cacheDir, $loader]), |
|
66 | - new MountPoint('\OC\Files\Storage\Local', '/' . $user->getUID() . '/uploads', ['datadir' => $cacheDir . '/uploads', $loader]) |
|
65 | + new MountPoint('\OC\Files\Storage\Local', '/'.$user->getUID().'/cache', ['datadir' => $cacheDir, $loader]), |
|
66 | + new MountPoint('\OC\Files\Storage\Local', '/'.$user->getUID().'/uploads', ['datadir' => $cacheDir.'/uploads', $loader]) |
|
67 | 67 | ]; |
68 | 68 | } else { |
69 | 69 | return []; |
@@ -133,7 +133,7 @@ discard block |
||
133 | 133 | foreach ($users as $user) { |
134 | 134 | $event->setAffectedUser($user) |
135 | 135 | ->setSubject( |
136 | - $user === $currentUser ? $action . '_self' : $action, |
|
136 | + $user === $currentUser ? $action.'_self' : $action, |
|
137 | 137 | [ |
138 | 138 | 'actor' => $currentUser, |
139 | 139 | 'calendar' => [ |
@@ -186,7 +186,7 @@ discard block |
||
186 | 186 | $event, |
187 | 187 | $calendarData, |
188 | 188 | Calendar::SUBJECT_UNSHARE_USER, |
189 | - Calendar::SUBJECT_DELETE . '_self' |
|
189 | + Calendar::SUBJECT_DELETE.'_self' |
|
190 | 190 | ); |
191 | 191 | |
192 | 192 | if ($owner !== $principal[2]) { |
@@ -201,15 +201,15 @@ discard block |
||
201 | 201 | ]; |
202 | 202 | |
203 | 203 | if ($owner === $event->getAuthor()) { |
204 | - $subject = Calendar::SUBJECT_UNSHARE_USER . '_you'; |
|
204 | + $subject = Calendar::SUBJECT_UNSHARE_USER.'_you'; |
|
205 | 205 | } else if ($principal[2] === $event->getAuthor()) { |
206 | - $subject = Calendar::SUBJECT_UNSHARE_USER . '_self'; |
|
206 | + $subject = Calendar::SUBJECT_UNSHARE_USER.'_self'; |
|
207 | 207 | } else { |
208 | 208 | $event->setAffectedUser($event->getAuthor()) |
209 | - ->setSubject(Calendar::SUBJECT_UNSHARE_USER . '_you', $parameters); |
|
209 | + ->setSubject(Calendar::SUBJECT_UNSHARE_USER.'_you', $parameters); |
|
210 | 210 | $this->activityManager->publish($event); |
211 | 211 | |
212 | - $subject = Calendar::SUBJECT_UNSHARE_USER . '_by'; |
|
212 | + $subject = Calendar::SUBJECT_UNSHARE_USER.'_by'; |
|
213 | 213 | } |
214 | 214 | |
215 | 215 | $event->setAffectedUser($owner) |
@@ -230,13 +230,13 @@ discard block |
||
230 | 230 | ]; |
231 | 231 | |
232 | 232 | if ($owner === $event->getAuthor()) { |
233 | - $subject = Calendar::SUBJECT_UNSHARE_GROUP . '_you'; |
|
233 | + $subject = Calendar::SUBJECT_UNSHARE_GROUP.'_you'; |
|
234 | 234 | } else { |
235 | 235 | $event->setAffectedUser($event->getAuthor()) |
236 | - ->setSubject(Calendar::SUBJECT_UNSHARE_GROUP . '_you', $parameters); |
|
236 | + ->setSubject(Calendar::SUBJECT_UNSHARE_GROUP.'_you', $parameters); |
|
237 | 237 | $this->activityManager->publish($event); |
238 | 238 | |
239 | - $subject = Calendar::SUBJECT_UNSHARE_GROUP . '_by'; |
|
239 | + $subject = Calendar::SUBJECT_UNSHARE_GROUP.'_by'; |
|
240 | 240 | } |
241 | 241 | |
242 | 242 | $event->setAffectedUser($owner) |
@@ -272,13 +272,13 @@ discard block |
||
272 | 272 | ]; |
273 | 273 | |
274 | 274 | if ($owner === $event->getAuthor()) { |
275 | - $subject = Calendar::SUBJECT_SHARE_USER . '_you'; |
|
275 | + $subject = Calendar::SUBJECT_SHARE_USER.'_you'; |
|
276 | 276 | } else { |
277 | 277 | $event->setAffectedUser($event->getAuthor()) |
278 | - ->setSubject(Calendar::SUBJECT_SHARE_USER . '_you', $parameters); |
|
278 | + ->setSubject(Calendar::SUBJECT_SHARE_USER.'_you', $parameters); |
|
279 | 279 | $this->activityManager->publish($event); |
280 | 280 | |
281 | - $subject = Calendar::SUBJECT_SHARE_USER . '_by'; |
|
281 | + $subject = Calendar::SUBJECT_SHARE_USER.'_by'; |
|
282 | 282 | } |
283 | 283 | |
284 | 284 | $event->setAffectedUser($owner) |
@@ -299,13 +299,13 @@ discard block |
||
299 | 299 | ]; |
300 | 300 | |
301 | 301 | if ($owner === $event->getAuthor()) { |
302 | - $subject = Calendar::SUBJECT_SHARE_GROUP . '_you'; |
|
302 | + $subject = Calendar::SUBJECT_SHARE_GROUP.'_you'; |
|
303 | 303 | } else { |
304 | 304 | $event->setAffectedUser($event->getAuthor()) |
305 | - ->setSubject(Calendar::SUBJECT_SHARE_GROUP . '_you', $parameters); |
|
305 | + ->setSubject(Calendar::SUBJECT_SHARE_GROUP.'_you', $parameters); |
|
306 | 306 | $this->activityManager->publish($event); |
307 | 307 | |
308 | - $subject = Calendar::SUBJECT_SHARE_GROUP . '_by'; |
|
308 | + $subject = Calendar::SUBJECT_SHARE_GROUP.'_by'; |
|
309 | 309 | } |
310 | 310 | |
311 | 311 | $event->setAffectedUser($owner) |
@@ -403,7 +403,7 @@ discard block |
||
403 | 403 | } |
404 | 404 | |
405 | 405 | $object = $this->getObjectNameAndType($objectData); |
406 | - $action = $action . '_' . $object['type']; |
|
406 | + $action = $action.'_'.$object['type']; |
|
407 | 407 | |
408 | 408 | if ($object['type'] === 'todo' && strpos($action, Event::SUBJECT_OBJECT_UPDATE) === 0 && $object['status'] === 'COMPLETED') { |
409 | 409 | $action .= '_completed'; |
@@ -423,7 +423,7 @@ discard block |
||
423 | 423 | foreach ($users as $user) { |
424 | 424 | $event->setAffectedUser($user) |
425 | 425 | ->setSubject( |
426 | - $user === $currentUser ? $action . '_self' : $action, |
|
426 | + $user === $currentUser ? $action.'_self' : $action, |
|
427 | 427 | [ |
428 | 428 | 'actor' => $event->getAuthor(), |
429 | 429 | 'calendar' => [ |
@@ -448,7 +448,7 @@ discard block |
||
448 | 448 | protected function getObjectNameAndType(array $objectData) { |
449 | 449 | $vObject = Reader::read($objectData['calendardata']); |
450 | 450 | $component = $componentType = null; |
451 | - foreach($vObject->getComponents() as $component) { |
|
451 | + foreach ($vObject->getComponents() as $component) { |
|
452 | 452 | if (in_array($component->name, ['VEVENT', 'VTODO'])) { |
453 | 453 | $componentType = $component->name; |
454 | 454 | break; |
@@ -6,5 +6,5 @@ |
||
6 | 6 | $baseDir = $vendorDir; |
7 | 7 | |
8 | 8 | return array( |
9 | - 'OCA\\Files_Sharing\\' => array($baseDir . '/../lib'), |
|
9 | + 'OCA\\Files_Sharing\\' => array($baseDir.'/../lib'), |
|
10 | 10 | ); |
@@ -6,5 +6,5 @@ |
||
6 | 6 | $baseDir = $vendorDir; |
7 | 7 | |
8 | 8 | return array( |
9 | - 'OCA\\AdminAudit\\' => array($baseDir . '/../lib'), |
|
9 | + 'OCA\\AdminAudit\\' => array($baseDir.'/../lib'), |
|
10 | 10 | ); |
@@ -6,5 +6,5 @@ |
||
6 | 6 | $baseDir = $vendorDir; |
7 | 7 | |
8 | 8 | return array( |
9 | - 'OCA\\DAV\\' => array($baseDir . '/../lib'), |
|
9 | + 'OCA\\DAV\\' => array($baseDir.'/../lib'), |
|
10 | 10 | ); |
@@ -6,5 +6,5 @@ |
||
6 | 6 | $baseDir = $vendorDir; |
7 | 7 | |
8 | 8 | return array( |
9 | - 'OCA\\Comments\\' => array($baseDir . '/../lib'), |
|
9 | + 'OCA\\Comments\\' => array($baseDir.'/../lib'), |
|
10 | 10 | ); |