Completed
Pull Request — master (#1875)
by
unknown
28s
created
lib/Model/FileCacheWrapper.php 1 patch
Spacing   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -456,7 +456,7 @@  discard block
 block discarded – undo
456 456
 		}
457 457
 
458 458
 		$path = $this->getPath();
459
-		[$storageType,] = explode('::', $this->getStorage(), 2);
459
+		[$storageType, ] = explode('::', $this->getStorage(), 2);
460 460
 
461 461
 		if ($path === '') {
462 462
 			// we only accept empty path on external storage
@@ -508,29 +508,29 @@  discard block
 block discarded – undo
508 508
 	 * @throws FileCacheNotFoundException
509 509
 	 */
510 510
 	public function importFromDatabase(array $data, string $prefix = ''): IQueryRow {
511
-		if ($this->getInt($prefix . 'fileid', $data) === 0) {
511
+		if ($this->getInt($prefix.'fileid', $data) === 0) {
512 512
 			throw new FileCacheNotFoundException();
513 513
 		}
514 514
 
515
-		$this->setId($this->getInt($prefix . 'fileid', $data));
516
-		$this->setPath($this->get($prefix . 'path', $data));
517
-		$this->setPermissions($this->getInt($prefix . 'permissions', $data));
518
-		$this->setStorageId($this->getInt($prefix . 'storage', $data));
519
-		$this->setPathHash($this->get($prefix . 'path_hash', $data));
520
-		$this->setParent($this->getInt($prefix . 'parent', $data));
521
-		$this->setName($this->get($prefix . 'name', $data));
522
-		$this->setMimeType($this->getInt($prefix . 'mimetype', $data));
523
-		$this->setMimePart($this->getInt($prefix . 'mimepart', $data));
524
-		$this->setSize($this->getInt($prefix . 'size', $data));
525
-		$this->setMTime($this->getInt($prefix . 'mtime', $data));
526
-		$this->setStorageMTime($this->getInt($prefix . 'storage_mtime', $data));
527
-		$this->setEncrypted($this->getBool($prefix . 'encrypted', $data));
528
-		$this->setUnencryptedSize($this->getInt($prefix . 'unencrypted_size', $data));
529
-		$this->setEtag($this->get($prefix . 'etag', $data));
530
-		$this->setChecksum($this->get($prefix . 'checksum', $data));
515
+		$this->setId($this->getInt($prefix.'fileid', $data));
516
+		$this->setPath($this->get($prefix.'path', $data));
517
+		$this->setPermissions($this->getInt($prefix.'permissions', $data));
518
+		$this->setStorageId($this->getInt($prefix.'storage', $data));
519
+		$this->setPathHash($this->get($prefix.'path_hash', $data));
520
+		$this->setParent($this->getInt($prefix.'parent', $data));
521
+		$this->setName($this->get($prefix.'name', $data));
522
+		$this->setMimeType($this->getInt($prefix.'mimetype', $data));
523
+		$this->setMimePart($this->getInt($prefix.'mimepart', $data));
524
+		$this->setSize($this->getInt($prefix.'size', $data));
525
+		$this->setMTime($this->getInt($prefix.'mtime', $data));
526
+		$this->setStorageMTime($this->getInt($prefix.'storage_mtime', $data));
527
+		$this->setEncrypted($this->getBool($prefix.'encrypted', $data));
528
+		$this->setUnencryptedSize($this->getInt($prefix.'unencrypted_size', $data));
529
+		$this->setEtag($this->get($prefix.'etag', $data));
530
+		$this->setChecksum($this->get($prefix.'checksum', $data));
531 531
 
532 532
 		// small hack as there is no reason to call a recursive method for a single entry from the table
533
-		$this->setStorage($this->get($prefix . CoreQueryBuilder::STORAGES . '_id', $data));
533
+		$this->setStorage($this->get($prefix.CoreQueryBuilder::STORAGES.'_id', $data));
534 534
 
535 535
 		return $this;
536 536
 	}
Please login to merge, or discard this patch.
lib/Service/ActivityService.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -75,7 +75,7 @@
 block discarded – undo
75 75
 		$event->setSubject('circle_create', ['circle' => json_encode($circle)]);
76 76
 
77 77
 		$this->userManager->callForSeenUsers(
78
-			function ($user) use ($event) {
78
+			function($user) use ($event) {
79 79
 				/** @var IUser $user */
80 80
 				$this->publishEvent($event, [$user]);
81 81
 			}
Please login to merge, or discard this patch.
lib/Db/CircleRequest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -184,8 +184,8 @@
 block discarded – undo
184 184
 		$qb->filterCircles(CoreQueryBuilder::CIRCLE, $probe);
185 185
 		if (!is_null($initiator)) {
186 186
 			$qb->limitToInitiator(CoreQueryBuilder::CIRCLE, $initiator);
187
-			$qb->orderBy($qb->generateAlias(CoreQueryBuilder::CIRCLE, CoreQueryBuilder::INITIATOR) . '.level', 'desc');
188
-			$qb->addOrderBy(CoreQueryBuilder::CIRCLE . '.display_name', 'asc');
187
+			$qb->orderBy($qb->generateAlias(CoreQueryBuilder::CIRCLE, CoreQueryBuilder::INITIATOR).'.level', 'desc');
188
+			$qb->addOrderBy(CoreQueryBuilder::CIRCLE.'.display_name', 'asc');
189 189
 		}
190 190
 		if ($probe->hasFilterMember()) {
191 191
 			$qb->limitToDirectMembership(CoreQueryBuilder::CIRCLE, $probe->getFilterMember());
Please login to merge, or discard this patch.
lib/Activity/Provider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -68,7 +68,7 @@
 block discarded – undo
68 68
 			$this->parseAsNonMember($event, $circle);
69 69
 			$this->parseAsMember($event, $circle, $params);
70 70
 			$this->parseAsModerator($event, $circle, $params);
71
-		} catch (FakeException|InvalidItemException $e) {
71
+		} catch (FakeException | InvalidItemException $e) {
72 72
 			/** clean exit */
73 73
 		}
74 74
 
Please login to merge, or discard this patch.
lib/Handlers/WebfingerHandler.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -87,7 +87,7 @@
 block discarded – undo
87 87
 				'version' => $this->configService->getAppValue('installed_version'),
88 88
 				'api' => Application::APP_API
89 89
 			];
90
-		} catch (UnknownInterfaceException|SignatoryException $e) {
90
+		} catch (UnknownInterfaceException | SignatoryException $e) {
91 91
 			return $response;
92 92
 		}
93 93
 
Please login to merge, or discard this patch.
lib/Dashboard/TeamDashboardWidget.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@
 block discarded – undo
76 76
 				->setItemsLimit($limit)
77 77
 				->setItemsOffset($since ? (int)$since : 0);
78 78
 
79
-			$circles = array_map(function (Circle $circle) {
79
+			$circles = array_map(function(Circle $circle) {
80 80
 				return new WidgetItem(
81 81
 					$circle->getDisplayName(),
82 82
 					'',
Please login to merge, or discard this patch.
lib/FileSharingTeamResourceProvider.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -59,18 +59,18 @@  discard block
 block discarded – undo
59 59
 		}
60 60
 
61 61
 		$shares = $this->shareByCircleProvider->getSharesToCircle($teamId);
62
-		usort($shares, function ($a, $b) {
62
+		usort($shares, function($a, $b) {
63 63
 			return (int)($b->getItemType() === 'folder') - (int)($a->getItemType() === 'folder');
64 64
 		});
65
-		return array_map(function (ShareWrapper $shareWrapper) {
65
+		return array_map(function(ShareWrapper $shareWrapper) {
66 66
 			$isFolder = $shareWrapper->getItemType() === 'folder';
67 67
 			return new TeamResource(
68 68
 				$this,
69 69
 				(string)$shareWrapper->getFileSource(),
70 70
 				basename($shareWrapper->getFileTarget()),
71
-				$this->urlGenerator->getAbsoluteURL('/index.php/f/' . $shareWrapper->getFileSource()),
71
+				$this->urlGenerator->getAbsoluteURL('/index.php/f/'.$shareWrapper->getFileSource()),
72 72
 				iconSvg: $isFolder ? '<svg xmlns="http://www.w3.org/2000/svg" id="mdi-folder" viewBox="0 0 24 24"><path d="M10,4H4C2.89,4 2,4.89 2,6V18A2,2 0 0,0 4,20H20A2,2 0 0,0 22,18V8C22,6.89 21.1,6 20,6H12L10,4Z" /></svg>' : null,
73
-				iconURL: !$isFolder ?
73
+				iconURL : !$isFolder ?
74 74
 					$this->urlGenerator->linkToRouteAbsolute('core.preview.getPreviewByFileId', ['fileId' => $shareWrapper->getFileSource(), 'mimeFallback' => true, ])
75 75
 					: null,
76 76
 			);
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
 			return false;
83 83
 		}
84 84
 
85
-		return count(array_filter($this->getSharedWith($teamId), function (TeamResource $resource) use ($resourceId) {
85
+		return count(array_filter($this->getSharedWith($teamId), function(TeamResource $resource) use ($resourceId) {
86 86
 			return $resource->getId() === $resourceId;
87 87
 		})) !== 0;
88 88
 	}
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
 
95 95
 		$shares = $this->shareByCircleProvider->getSharesByFileId((int)$resourceId);
96 96
 
97
-		return array_map(function ($share) {
97
+		return array_map(function($share) {
98 98
 			return $share->getSharedWith();
99 99
 		}, $shares);
100 100
 	}
Please login to merge, or discard this patch.
lib/Activity/ProviderParser.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -125,7 +125,7 @@
 block discarded – undo
125 125
 				continue;
126 126
 			}
127 127
 
128
-			$replace['{' . $k . '}'] = $data[$k]['_parsed'];
128
+			$replace['{'.$k.'}'] = $data[$k]['_parsed'];
129 129
 		}
130 130
 
131 131
 		$event->setParsedSubject(strtr($line, $replace));
Please login to merge, or discard this patch.
lib/Command/CirclesMaintenance.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
 				'<error>WARNING! You are about to delete all data related to the Circles App!</error>'
109 109
 			);
110 110
 			$question = new ConfirmationQuestion(
111
-				'<comment>Do you really want to ' . $action . ' Circles ?</comment> (y/N) ', false,
111
+				'<comment>Do you really want to '.$action.' Circles ?</comment> (y/N) ', false,
112 112
 				'/^(y|Y)/i'
113 113
 			);
114 114
 
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
 			$output->writeln('<error>WARNING! This operation is not reversible.</error>');
124 124
 
125 125
 			$question = new Question(
126
-				'<comment>Please confirm this destructive operation by typing \'' . $action
126
+				'<comment>Please confirm this destructive operation by typing \''.$action
127 127
 				. '\'</comment>: ', ''
128 128
 			);
129 129
 
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
140 140
 				$this->coreRequestBuilder->uninstall();
141 141
 			}
142 142
 
143
-			$output->writeln('<info>' . $action . ' done</info>');
143
+			$output->writeln('<info>'.$action.' done</info>');
144 144
 
145 145
 			return 0;
146 146
 		}
@@ -171,7 +171,7 @@  discard block
 block discarded – undo
171 171
 		$federatedUser = $this->federatedUserService->getLocalFederatedUser($userId);
172 172
 		$displayName = $this->maintenanceService->updateDisplayName($federatedUser);
173 173
 		if ($displayName !== '') {
174
-			$output->writeln('Display name of ' . $federatedUser->getSingleId() . ' updated to ' . $displayName);
174
+			$output->writeln('Display name of '.$federatedUser->getSingleId().' updated to '.$displayName);
175 175
 		}
176 176
 
177 177
 		return 0;
@@ -186,7 +186,7 @@  discard block
 block discarded – undo
186 186
 			try {
187 187
 				$this->refreshSingleDisplayName($row['uid'], $output);
188 188
 			} catch (Exception $e) {
189
-				$output->writeln(get_class($e) . ' while trying to update display name of ' . $row['uid']);
189
+				$output->writeln(get_class($e).' while trying to update display name of '.$row['uid']);
190 190
 			}
191 191
 		}
192 192
 	}
Please login to merge, or discard this patch.