@@ -174,14 +174,14 @@ discard block |
||
174 | 174 | return; |
175 | 175 | } |
176 | 176 | |
177 | - $ns = '{' . $this::NS_OWNCLOUD . '}'; |
|
177 | + $ns = '{'.$this::NS_OWNCLOUD.'}'; |
|
178 | 178 | $requestedProps = []; |
179 | 179 | $filterRules = []; |
180 | 180 | |
181 | 181 | // parse report properties and gather filter info |
182 | 182 | foreach ($report as $reportProps) { |
183 | 183 | $name = $reportProps['name']; |
184 | - if ($name === $ns . 'filter-rules') { |
|
184 | + if ($name === $ns.'filter-rules') { |
|
185 | 185 | $filterRules = $reportProps['value']; |
186 | 186 | } else if ($name === '{DAV:}prop') { |
187 | 187 | // propfind properties |
@@ -242,7 +242,7 @@ discard block |
||
242 | 242 | if (empty($filesUri)) { |
243 | 243 | return ''; |
244 | 244 | } |
245 | - return '/' . $filesUri; |
|
245 | + return '/'.$filesUri; |
|
246 | 246 | } |
247 | 247 | |
248 | 248 | /** |
@@ -254,19 +254,19 @@ discard block |
||
254 | 254 | * @throws TagNotFoundException whenever a tag was not found |
255 | 255 | */ |
256 | 256 | protected function processFilterRules($filterRules) { |
257 | - $ns = '{' . $this::NS_OWNCLOUD . '}'; |
|
257 | + $ns = '{'.$this::NS_OWNCLOUD.'}'; |
|
258 | 258 | $resultFileIds = null; |
259 | 259 | $systemTagIds = []; |
260 | 260 | $circlesIds = []; |
261 | 261 | $favoriteFilter = null; |
262 | 262 | foreach ($filterRules as $filterRule) { |
263 | - if ($filterRule['name'] === $ns . 'systemtag') { |
|
263 | + if ($filterRule['name'] === $ns.'systemtag') { |
|
264 | 264 | $systemTagIds[] = $filterRule['value']; |
265 | 265 | } |
266 | 266 | if ($filterRule['name'] === self::CIRCLE_PROPERTYNAME) { |
267 | 267 | $circlesIds[] = $filterRule['value']; |
268 | 268 | } |
269 | - if ($filterRule['name'] === $ns . 'favorite') { |
|
269 | + if ($filterRule['name'] === $ns.'favorite') { |
|
270 | 270 | $favoriteFilter = true; |
271 | 271 | } |
272 | 272 | |
@@ -315,7 +315,7 @@ discard block |
||
315 | 315 | } |
316 | 316 | |
317 | 317 | if (!empty($unknownTagIds)) { |
318 | - throw new TagNotFoundException('Tag with ids ' . implode(', ', $unknownTagIds) . ' not found'); |
|
318 | + throw new TagNotFoundException('Tag with ids '.implode(', ', $unknownTagIds).' not found'); |
|
319 | 319 | } |
320 | 320 | } |
321 | 321 | |
@@ -367,7 +367,7 @@ discard block |
||
367 | 367 | public function prepareResponses($filesUri, $requestedProps, $nodes) { |
368 | 368 | $responses = []; |
369 | 369 | foreach ($nodes as $node) { |
370 | - $propFind = new PropFind($filesUri . $node->getPath(), $requestedProps); |
|
370 | + $propFind = new PropFind($filesUri.$node->getPath(), $requestedProps); |
|
371 | 371 | |
372 | 372 | $this->server->getPropertiesByNode($propFind, $node); |
373 | 373 | // copied from Sabre Server's getPropertiesForPath |
@@ -380,7 +380,7 @@ discard block |
||
380 | 380 | } |
381 | 381 | |
382 | 382 | $responses[] = new Response( |
383 | - rtrim($this->server->getBaseUri(), '/') . $filesUri . $node->getPath(), |
|
383 | + rtrim($this->server->getBaseUri(), '/').$filesUri.$node->getPath(), |
|
384 | 384 | $result, |
385 | 385 | 200 |
386 | 386 | ); |
@@ -119,7 +119,7 @@ discard block |
||
119 | 119 | $principals = []; |
120 | 120 | |
121 | 121 | if ($prefixPath === $this->principalPrefix) { |
122 | - foreach($this->userManager->search('') as $user) { |
|
122 | + foreach ($this->userManager->search('') as $user) { |
|
123 | 123 | $principals[] = $this->userToPrincipal($user); |
124 | 124 | } |
125 | 125 | } |
@@ -192,7 +192,7 @@ discard block |
||
192 | 192 | $groups = $this->groupManager->getUserGroups($user); |
193 | 193 | $groups = array_map(function($group) { |
194 | 194 | /** @var IGroup $group */ |
195 | - return 'principals/groups/' . urlencode($group->getGID()); |
|
195 | + return 'principals/groups/'.urlencode($group->getGID()); |
|
196 | 196 | }, $groups); |
197 | 197 | |
198 | 198 | return $groups; |
@@ -265,7 +265,7 @@ discard block |
||
265 | 265 | } |
266 | 266 | } |
267 | 267 | |
268 | - $carry[] = $this->principalPrefix . '/' . $user->getUID(); |
|
268 | + $carry[] = $this->principalPrefix.'/'.$user->getUID(); |
|
269 | 269 | return $carry; |
270 | 270 | }, []); |
271 | 271 | break; |
@@ -282,7 +282,7 @@ discard block |
||
282 | 282 | } |
283 | 283 | } |
284 | 284 | |
285 | - $carry[] = $this->principalPrefix . '/' . $user->getUID(); |
|
285 | + $carry[] = $this->principalPrefix.'/'.$user->getUID(); |
|
286 | 286 | return $carry; |
287 | 287 | }, []); |
288 | 288 | break; |
@@ -368,7 +368,7 @@ discard block |
||
368 | 368 | } |
369 | 369 | } |
370 | 370 | |
371 | - return $this->principalPrefix . '/' . $user->getUID(); |
|
371 | + return $this->principalPrefix.'/'.$user->getUID(); |
|
372 | 372 | } |
373 | 373 | } |
374 | 374 | if (substr($uri, 0, 10) === 'principal:') { |
@@ -390,7 +390,7 @@ discard block |
||
390 | 390 | $userId = $user->getUID(); |
391 | 391 | $displayName = $user->getDisplayName(); |
392 | 392 | $principal = [ |
393 | - 'uri' => $this->principalPrefix . '/' . $userId, |
|
393 | + 'uri' => $this->principalPrefix.'/'.$userId, |
|
394 | 394 | '{DAV:}displayname' => is_null($displayName) ? $userId : $displayName, |
395 | 395 | '{urn:ietf:params:xml:ns:caldav}calendar-user-type' => 'INDIVIDUAL', |
396 | 396 | ]; |
@@ -421,9 +421,9 @@ discard block |
||
421 | 421 | |
422 | 422 | try { |
423 | 423 | $circle = \OCA\Circles\Api\v1\Circles::detailsCircle($circleUniqueId, true); |
424 | - } catch(QueryException $ex) { |
|
424 | + } catch (QueryException $ex) { |
|
425 | 425 | return null; |
426 | - } catch(CircleDoesNotExistException $ex) { |
|
426 | + } catch (CircleDoesNotExistException $ex) { |
|
427 | 427 | return null; |
428 | 428 | } |
429 | 429 | |
@@ -432,7 +432,7 @@ discard block |
||
432 | 432 | } |
433 | 433 | |
434 | 434 | $principal = [ |
435 | - 'uri' => 'principals/circles/' . $circleUniqueId, |
|
435 | + 'uri' => 'principals/circles/'.$circleUniqueId, |
|
436 | 436 | '{DAV:}displayname' => $circle->getName(), |
437 | 437 | ]; |
438 | 438 | |
@@ -464,7 +464,7 @@ discard block |
||
464 | 464 | |
465 | 465 | $circles = array_map(function($circle) { |
466 | 466 | /** @var \OCA\Circles\Model\Circle $circle */ |
467 | - return 'principals/circles/' . urlencode($circle->getUniqueId()); |
|
467 | + return 'principals/circles/'.urlencode($circle->getUniqueId()); |
|
468 | 468 | }, $circles); |
469 | 469 | |
470 | 470 | return $circles; |