Passed
Push — master ( b56cb4...836ba4 )
by Morris
15:06 queued 10s
created
apps/files_sharing/lib/Controller/ShareController.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
 
216 216
 	protected function authSucceeded() {
217 217
 		// For share this was always set so it is still used in other apps
218
-		$this->session->set('public_link_authenticated', (string)$this->share->getId());
218
+		$this->session->set('public_link_authenticated', (string) $this->share->getId());
219 219
 	}
220 220
 
221 221
 	protected function authFailed() {
@@ -236,7 +236,7 @@  discard block
 block discarded – undo
236 236
 		$itemType = $itemSource = $uidOwner = '';
237 237
 		$token = $share;
238 238
 		$exception = null;
239
-		if($share instanceof \OCP\Share\IShare) {
239
+		if ($share instanceof \OCP\Share\IShare) {
240 240
 			try {
241 241
 				$token = $share->getToken();
242 242
 				$uidOwner = $share->getSharedBy();
@@ -255,7 +255,7 @@  discard block
 block discarded – undo
255 255
 			'errorCode' => $errorCode,
256 256
 			'errorMessage' => $errorMessage,
257 257
 		]);
258
-		if(!is_null($exception)) {
258
+		if (!is_null($exception)) {
259 259
 			throw $exception;
260 260
 		}
261 261
 	}
@@ -385,7 +385,7 @@  discard block
 block discarded – undo
385 385
 		$shareTmpl['previewURL'] = $shareTmpl['downloadURL'];
386 386
 
387 387
 		if ($shareTmpl['previewSupported']) {
388
-			$shareTmpl['previewImage'] = $this->urlGenerator->linkToRouteAbsolute( 'files_sharing.PublicPreview.getPreview',
388
+			$shareTmpl['previewImage'] = $this->urlGenerator->linkToRouteAbsolute('files_sharing.PublicPreview.getPreview',
389 389
 				['x' => 200, 'y' => 200, 'file' => $shareTmpl['directory_path'], 'token' => $shareTmpl['dirToken']]);
390 390
 			$ogPreview = $shareTmpl['previewImage'];
391 391
 
@@ -436,7 +436,7 @@  discard block
 block discarded – undo
436 436
 
437 437
 		// OpenGraph Support: http://ogp.me/
438 438
 		\OCP\Util::addHeader('meta', ['property' => "og:title", 'content' => $shareTmpl['filename']]);
439
-		\OCP\Util::addHeader('meta', ['property' => "og:description", 'content' => $this->defaults->getName() . ($this->defaults->getSlogan() !== '' ? ' - ' . $this->defaults->getSlogan() : '')]);
439
+		\OCP\Util::addHeader('meta', ['property' => "og:description", 'content' => $this->defaults->getName().($this->defaults->getSlogan() !== '' ? ' - '.$this->defaults->getSlogan() : '')]);
440 440
 		\OCP\Util::addHeader('meta', ['property' => "og:site_name", 'content' => $this->defaults->getName()]);
441 441
 		\OCP\Util::addHeader('meta', ['property' => "og:url", 'content' => $shareTmpl['shareUrl']]);
442 442
 		\OCP\Util::addHeader('meta', ['property' => "og:type", 'content' => "object"]);
@@ -486,7 +486,7 @@  discard block
 block discarded – undo
486 486
 
487 487
 		$share = $this->shareManager->getShareByToken($token);
488 488
 
489
-		if(!($share->getPermissions() & \OCP\Constants::PERMISSION_READ)) {
489
+		if (!($share->getPermissions() & \OCP\Constants::PERMISSION_READ)) {
490 490
 			return new \OCP\AppFramework\Http\DataResponse('Share is read-only');
491 491
 		}
492 492
 
@@ -564,7 +564,7 @@  discard block
 block discarded – undo
564 564
 
565 565
 		$this->emitAccessShareHook($share);
566 566
 
567
-		$server_params = array( 'head' => $this->request->getMethod() === 'HEAD' );
567
+		$server_params = array('head' => $this->request->getMethod() === 'HEAD');
568 568
 
569 569
 		/**
570 570
 		 * Http range requests support
Please login to merge, or discard this patch.