Completed
Pull Request — master (#439)
by Joas
01:52
created
lib/GlobalScale/GSMount/Mount.php 1 patch
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
 	/**
57 57
 	 * Mount constructor.
58 58
 	 *
59
-	 * @param $storage
59
+	 * @param string $storage
60 60
 	 * @param string $mountPoint
61 61
 	 * @param array $options
62 62
 	 * @param MountManager $manager
@@ -90,8 +90,8 @@  discard block
 block discarded – undo
90 90
 	/**
91 91
 	 * Remove the mount points
92 92
 	 *
93
-	 * @return mixed
94
-	 * @return bool
93
+	 * @return boolean
94
+	 * @return boolean
95 95
 	 */
96 96
 	public function removeMount() {
97 97
 		return $this->mountManager->unshare($this->gsShareId);
Please login to merge, or discard this patch.
lib/GlobalScale/GSMount/MountManager.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -109,7 +109,7 @@
 block discarded – undo
109 109
 	 * @return string
110 110
 	 */
111 111
 	protected function stripPath($path) {
112
-		$prefix = '/' . $this->userId . '/files';
112
+		$prefix = '/'.$this->userId.'/files';
113 113
 
114 114
 		return rtrim(substr($path, strlen($prefix)), '/');
115 115
 	}
Please login to merge, or discard this patch.
lib/Model/GlobalScale/GSShare.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -154,7 +154,7 @@  discard block
 block discarded – undo
154 154
 			return $mountPoint;
155 155
 		}
156 156
 
157
-		return '/' . $userId . '/files/' . ltrim($mountPoint, '/');
157
+		return '/'.$userId.'/files/'.ltrim($mountPoint, '/');
158 158
 	}
159 159
 
160 160
 	/**
@@ -293,7 +293,7 @@  discard block
 block discarded – undo
293 293
 	public function toMount(string $userId, string $protocol = 'https'): array {
294 294
 		return [
295 295
 			'owner'       => $this->getOwner(),
296
-			'remote'      => $protocol . '://' . $this->getInstance(),
296
+			'remote'      => $protocol.'://'.$this->getInstance(),
297 297
 			'token'       => $this->getToken(),
298 298
 			'share_token' => $this->getToken(),
299 299
 			'password'    => $this->getPassword(),
Please login to merge, or discard this patch.
lib/Db/GSSharesRequest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -121,11 +121,11 @@
 block discarded – undo
121 121
 
122 122
 	private function leftJoinMountPoint(IQueryBuilder $qb, string $userId) {
123 123
 		$expr = $qb->expr();
124
-		$pf = '' . $this->default_select_alias . '.';
124
+		$pf = ''.$this->default_select_alias.'.';
125 125
 
126 126
 		$on = $expr->andX();
127 127
 		$on->add($expr->eq('mp.user_id', $qb->createNamedParameter($userId)));
128
-		$on->add($expr->eq('mp.share_id', $pf . 'id'));
128
+		$on->add($expr->eq('mp.share_id', $pf.'id'));
129 129
 
130 130
 		/** @noinspection PhpMethodParametersCountMismatchInspection */
131 131
 		$qb->selectAlias('mp.mountPoint', 'gsshares_mountpoint')
Please login to merge, or discard this patch.
lib/Events/UserEvents.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -50,7 +50,7 @@
 block discarded – undo
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
 
Please login to merge, or discard this patch.
lib/GlobalScale/GSMount/MountProvider.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -148,13 +148,13 @@
 block discarded – undo
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) {
Please login to merge, or discard this patch.
lib/GlobalScale/FileShare.php 2 patches
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -257,7 +257,7 @@  discard block
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 	 *
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -105,14 +105,14 @@  discard block
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 		);
Please login to merge, or discard this patch.
lib/GlobalScale/FileUnshare.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -240,7 +240,7 @@
 block discarded – undo
240 240
 	/**
241 241
 	 * @param SimpleDataStore $data
242 242
 	 *
243
-	 * @return IShare
243
+	 * @return string
244 244
 	 * @throws ShareNotFound
245 245
 	 * @throws IllegalIDChangeException
246 246
 	 */
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
 			\OC::$server->getLogger()->log(3, '### 2');
92 92
 
93 93
 
94
-			$this->miscService->log('### ' . json_encode($event->getData()));
94
+			$this->miscService->log('### '.json_encode($event->getData()));
95 95
 
96 96
 			try {
97 97
 				$node = $share->getNode();
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
 
103 103
 			$event->getData()
104 104
 				  ->s('gs_federated', $share->getToken())
105
-				  ->s('gs_filename', '/' . $filename);
105
+				  ->s('gs_filename', '/'.$filename);
106 106
 		}
107 107
 
108 108
 	}
@@ -191,7 +191,7 @@  discard block
 block discarded – undo
191 191
 		}
192 192
 
193 193
 		$members =
194
-			$this->membersRequest->forceGetMembers($circle->getUniqueId(), Member::LEVEL_MEMBER, 0,true);
194
+			$this->membersRequest->forceGetMembers($circle->getUniqueId(), Member::LEVEL_MEMBER, 0, true);
195 195
 		foreach ($members AS $member) {
196 196
 			$this->parseMember($member);
197 197
 
@@ -200,7 +200,7 @@  discard block
 block discarded – undo
200 200
 			}
201 201
 
202 202
 			if ($member->getInstance() !== '') {
203
-				$this->miscService->log('#### GENERATE FEDERATED CIRCLES SHARE ' . $member->getInstance());
203
+				$this->miscService->log('#### GENERATE FEDERATED CIRCLES SHARE '.$member->getInstance());
204 204
 			}
205 205
 		}
206 206
 	}
Please login to merge, or discard this patch.
lib/Service/GSDownstreamService.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -155,7 +155,7 @@
 block discarded – undo
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
 
Please login to merge, or discard this patch.