Completed
Pull Request — master (#10075)
by
unknown
66:02 queued 36:49
created
apps/files_sharing/lib/ShareBackend/File.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
 	 */
97 97
 	public function generateTarget($filePath, $shareWith, $exclude = null) {
98 98
 		$shareFolder = \OCA\Files_Sharing\Helper::getShareFolder();
99
-		$target = \OC\Files\Filesystem::normalizePath($shareFolder . '/' . basename($filePath));
99
+		$target = \OC\Files\Filesystem::normalizePath($shareFolder.'/'.basename($filePath));
100 100
 
101 101
 		// for group shares we return the target right away
102 102
 		if ($shareWith === false) {
@@ -104,13 +104,13 @@  discard block
 block discarded – undo
104 104
 		}
105 105
 
106 106
 		\OC\Files\Filesystem::initMountPoints($shareWith);
107
-		$view = new \OC\Files\View('/' . $shareWith . '/files');
107
+		$view = new \OC\Files\View('/'.$shareWith.'/files');
108 108
 
109 109
 		if (!$view->is_dir($shareFolder)) {
110 110
 			$dir = '';
111 111
 			$subdirs = explode('/', $shareFolder);
112 112
 			foreach ($subdirs as $subdir) {
113
-				$dir = $dir . '/' . $subdir;
113
+				$dir = $dir.'/'.$subdir;
114 114
 				if (!$view->is_dir($dir)) {
115 115
 					$view->mkdir($dir);
116 116
 				}
@@ -237,7 +237,7 @@  discard block
 block discarded – undo
237 237
 		if ($share['item_type'] === 'folder' && $target !== '') {
238 238
 			// note: in case of ext storage mount points the path might be empty
239 239
 			// which would cause a leading slash to appear
240
-			$share['path'] = ltrim($share['path'] . '/' . $target, '/');
240
+			$share['path'] = ltrim($share['path'].'/'.$target, '/');
241 241
 		}
242 242
 		return self::resolveReshares($share);
243 243
 	}
Please login to merge, or discard this patch.
apps/updatenotification/lib/ResetTokenBackgroundJob.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -69,7 +69,7 @@
 block discarded – undo
69 69
 	 */
70 70
 	protected function run($argument) {
71 71
 		// Delete old tokens after 2 days
72
-		if($this->timeFactory->getTime() - $this->config->getAppValue('core', 'updater.secret.created', $this->timeFactory->getTime()) >= 172800) {
72
+		if ($this->timeFactory->getTime() - $this->config->getAppValue('core', 'updater.secret.created', $this->timeFactory->getTime()) >= 172800) {
73 73
 			$this->config->deleteSystemValue('updater.secret');
74 74
 		}
75 75
 	}
Please login to merge, or discard this patch.
apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
 
79 79
 		$uid = $user->getUID();
80 80
 		foreach (range(1, min([$number, 20])) as $i) {
81
-			$code = $this->random->generate(self::$CODE_LENGTH, ISecureRandom::CHAR_UPPER . ISecureRandom::CHAR_DIGITS);
81
+			$code = $this->random->generate(self::$CODE_LENGTH, ISecureRandom::CHAR_UPPER.ISecureRandom::CHAR_DIGITS);
82 82
 
83 83
 			$dbCode = new BackupCode();
84 84
 			$dbCode->setUserId($uid);
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
 		$codes = $this->mapper->getBackupCodes($user);
133 133
 		$total = count($codes);
134 134
 		$used = 0;
135
-		array_walk($codes, function (BackupCode $code) use (&$used) {
135
+		array_walk($codes, function(BackupCode $code) use (&$used) {
136 136
 			if (1 === (int) $code->getUsed()) {
137 137
 				$used++;
138 138
 			}
Please login to merge, or discard this patch.
apps/twofactor_backupcodes/lib/Db/BackupCodeMapper.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@
 block discarded – undo
47 47
 		$rows = $result->fetchAll();
48 48
 		$result->closeCursor();
49 49
 
50
-		return array_map(function ($row) {
50
+		return array_map(function($row) {
51 51
 			return BackupCode::fromRow($row);
52 52
 		}, $rows);
53 53
 	}
Please login to merge, or discard this patch.
apps/encryption/templates/altmail.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@  discard block
 block discarded – undo
3 3
 /** @var array $_ */
4 4
 
5 5
 print_unescaped($l->t("Hey there,\n\nthe admin enabled server-side-encryption. Your files were encrypted using the password '%s'.\n\nPlease login to the web interface, go to the section 'basic encryption module' of your personal settings and update your encryption password by entering this password into the 'old log-in password' field and your current login-password.\n\n", array($_['password'])));
6
-if ( isset($_['expiration']) ) {
6
+if (isset($_['expiration'])) {
7 7
 	print_unescaped($l->t("The share will expire on %s.", array($_['expiration'])));
8 8
 	print_unescaped("\n\n");
9 9
 }
@@ -12,5 +12,5 @@  discard block
 block discarded – undo
12 12
 ?>
13 13
 
14 14
 	--
15
-<?php p($theme->getName() . ' - ' . $theme->getSlogan()); ?>
15
+<?php p($theme->getName().' - '.$theme->getSlogan()); ?>
16 16
 <?php print_unescaped("\n".$theme->getBaseUrl());
Please login to merge, or discard this patch.
apps/encryption/lib/Util.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -163,7 +163,7 @@  discard block
 block discarded – undo
163 163
 	 * @return bool
164 164
 	 */
165 165
 	public function userHasFiles($uid) {
166
-		return $this->files->file_exists($uid . '/files');
166
+		return $this->files->file_exists($uid.'/files');
167 167
 	}
168 168
 
169 169
 	/**
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
 		if (count($parts) > 1) {
180 180
 			$owner = $parts[1];
181 181
 			if ($this->userManager->userExists($owner) === false) {
182
-				throw new \BadMethodCallException('Unknown user: ' .
182
+				throw new \BadMethodCallException('Unknown user: '.
183 183
 				'method expects path to a user folder relative to the data folder');
184 184
 			}
185 185
 
Please login to merge, or discard this patch.
apps/encryption/lib/Controller/SettingsController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -128,7 +128,7 @@
 block discarded – undo
128 128
 				$encryptedKey = $this->crypt->encryptPrivateKey($decryptedKey, $newPassword, $uid);
129 129
 				$header = $this->crypt->generateHeader();
130 130
 				if ($encryptedKey) {
131
-					$this->keyManager->setPrivateKey($uid, $header . $encryptedKey);
131
+					$this->keyManager->setPrivateKey($uid, $header.$encryptedKey);
132 132
 					$this->session->setPrivateKey($decryptedKey);
133 133
 					$result = true;
134 134
 				}
Please login to merge, or discard this patch.
apps/encryption/lib/Controller/RecoveryController.php 1 patch
Spacing   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -74,36 +74,36 @@  discard block
 block discarded – undo
74 74
 	public function adminRecovery($recoveryPassword, $confirmPassword, $adminEnableRecovery) {
75 75
 		// Check if both passwords are the same
76 76
 		if (empty($recoveryPassword)) {
77
-			$errorMessage = (string)$this->l->t('Missing recovery key password');
77
+			$errorMessage = (string) $this->l->t('Missing recovery key password');
78 78
 			return new DataResponse(['data' => ['message' => $errorMessage]],
79 79
 				Http::STATUS_BAD_REQUEST);
80 80
 		}
81 81
 
82 82
 		if (empty($confirmPassword)) {
83
-			$errorMessage = (string)$this->l->t('Please repeat the recovery key password');
83
+			$errorMessage = (string) $this->l->t('Please repeat the recovery key password');
84 84
 			return new DataResponse(['data' => ['message' => $errorMessage]],
85 85
 				Http::STATUS_BAD_REQUEST);
86 86
 		}
87 87
 
88 88
 		if ($recoveryPassword !== $confirmPassword) {
89
-			$errorMessage = (string)$this->l->t('Repeated recovery key password does not match the provided recovery key password');
89
+			$errorMessage = (string) $this->l->t('Repeated recovery key password does not match the provided recovery key password');
90 90
 			return new DataResponse(['data' => ['message' => $errorMessage]],
91 91
 				Http::STATUS_BAD_REQUEST);
92 92
 		}
93 93
 
94 94
 		if (isset($adminEnableRecovery) && $adminEnableRecovery === '1') {
95 95
 			if ($this->recovery->enableAdminRecovery($recoveryPassword)) {
96
-				return new DataResponse(['data' => ['message' => (string)$this->l->t('Recovery key successfully enabled')]]);
96
+				return new DataResponse(['data' => ['message' => (string) $this->l->t('Recovery key successfully enabled')]]);
97 97
 			}
98
-			return new DataResponse(['data' => ['message' => (string)$this->l->t('Could not enable recovery key. Please check your recovery key password!')]], Http::STATUS_BAD_REQUEST);
98
+			return new DataResponse(['data' => ['message' => (string) $this->l->t('Could not enable recovery key. Please check your recovery key password!')]], Http::STATUS_BAD_REQUEST);
99 99
 		} elseif (isset($adminEnableRecovery) && $adminEnableRecovery === '0') {
100 100
 			if ($this->recovery->disableAdminRecovery($recoveryPassword)) {
101
-				return new DataResponse(['data' => ['message' => (string)$this->l->t('Recovery key successfully disabled')]]);
101
+				return new DataResponse(['data' => ['message' => (string) $this->l->t('Recovery key successfully disabled')]]);
102 102
 			}
103
-			return new DataResponse(['data' => ['message' => (string)$this->l->t('Could not disable recovery key. Please check your recovery key password!')]], Http::STATUS_BAD_REQUEST);
103
+			return new DataResponse(['data' => ['message' => (string) $this->l->t('Could not disable recovery key. Please check your recovery key password!')]], Http::STATUS_BAD_REQUEST);
104 104
 		}
105 105
 		// this response should never be sent but just in case.
106
-		return new DataResponse(['data' => ['message' => (string)$this->l->t('Missing parameters')]], Http::STATUS_BAD_REQUEST);
106
+		return new DataResponse(['data' => ['message' => (string) $this->l->t('Missing parameters')]], Http::STATUS_BAD_REQUEST);
107 107
 	}
108 108
 
109 109
 	/**
@@ -115,22 +115,22 @@  discard block
 block discarded – undo
115 115
 	public function changeRecoveryPassword($newPassword, $oldPassword, $confirmPassword) {
116 116
 		//check if both passwords are the same
117 117
 		if (empty($oldPassword)) {
118
-			$errorMessage = (string)$this->l->t('Please provide the old recovery password');
118
+			$errorMessage = (string) $this->l->t('Please provide the old recovery password');
119 119
 			return new DataResponse(['data' => ['message' => $errorMessage]], Http::STATUS_BAD_REQUEST);
120 120
 		}
121 121
 
122 122
 		if (empty($newPassword)) {
123
-			$errorMessage = (string)$this->l->t('Please provide a new recovery password');
124
-			return new DataResponse (['data' => ['message' => $errorMessage]], Http::STATUS_BAD_REQUEST);
123
+			$errorMessage = (string) $this->l->t('Please provide a new recovery password');
124
+			return new DataResponse(['data' => ['message' => $errorMessage]], Http::STATUS_BAD_REQUEST);
125 125
 		}
126 126
 
127 127
 		if (empty($confirmPassword)) {
128
-			$errorMessage = (string)$this->l->t('Please repeat the new recovery password');
128
+			$errorMessage = (string) $this->l->t('Please repeat the new recovery password');
129 129
 			return new DataResponse(['data' => ['message' => $errorMessage]], Http::STATUS_BAD_REQUEST);
130 130
 		}
131 131
 
132 132
 		if ($newPassword !== $confirmPassword) {
133
-			$errorMessage = (string)$this->l->t('Repeated recovery key password does not match the provided recovery key password');
133
+			$errorMessage = (string) $this->l->t('Repeated recovery key password does not match the provided recovery key password');
134 134
 			return new DataResponse(['data' => ['message' => $errorMessage]], Http::STATUS_BAD_REQUEST);
135 135
 		}
136 136
 
@@ -141,14 +141,14 @@  discard block
 block discarded – undo
141 141
 			return new DataResponse(
142 142
 				[
143 143
 					'data' => [
144
-						'message' => (string)$this->l->t('Password successfully changed.')]
144
+						'message' => (string) $this->l->t('Password successfully changed.')]
145 145
 				]
146 146
 			);
147 147
 		}
148 148
 		return new DataResponse(
149 149
 			[
150 150
 				'data' => [
151
-					'message' => (string)$this->l->t('Could not change the password. Maybe the old password was not correct.')
151
+					'message' => (string) $this->l->t('Could not change the password. Maybe the old password was not correct.')
152 152
 				]
153 153
 			], Http::STATUS_BAD_REQUEST);
154 154
 	}
@@ -169,14 +169,14 @@  discard block
 block discarded – undo
169 169
 					return new DataResponse(
170 170
 						[
171 171
 							'data' => [
172
-								'message' => (string)$this->l->t('Recovery Key disabled')]
172
+								'message' => (string) $this->l->t('Recovery Key disabled')]
173 173
 						]
174 174
 					);
175 175
 				}
176 176
 				return new DataResponse(
177 177
 					[
178 178
 						'data' => [
179
-							'message' => (string)$this->l->t('Recovery Key enabled')]
179
+							'message' => (string) $this->l->t('Recovery Key enabled')]
180 180
 					]
181 181
 				);
182 182
 			}
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
 		return new DataResponse(
186 186
 			[
187 187
 				'data' => [
188
-					'message' => (string)$this->l->t('Could not enable the recovery key, please try again or contact your administrator')
188
+					'message' => (string) $this->l->t('Could not enable the recovery key, please try again or contact your administrator')
189 189
 				]
190 190
 			], Http::STATUS_BAD_REQUEST);
191 191
 	}
Please login to merge, or discard this patch.
apps/encryption/lib/Exceptions/PublicKeyMissingException.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
 	 * @param string $userId
30 30
 	 */
31 31
 	public function __construct($userId) {
32
-		if(empty($userId)) {
32
+		if (empty($userId)) {
33 33
 			$userId = "<no-user-id-given>";
34 34
 		}
35 35
 		parent::__construct("Public Key missing for user: $userId");
Please login to merge, or discard this patch.