Completed
Push — master ( 695e32...226e63 )
by Joas
26:45 queued 10:02
created
settings/templates/settings/admin/server.php 1 patch
Braces   +8 added lines, -3 removed lines patch added patch discarded remove patch
@@ -165,15 +165,20 @@
 block discarded – undo
165 165
 				<span class="crondate" title="<?php p($absolute_time);?>">
166 166
 				<?php p($l->t("Last job ran %s.", [$relative_time]));?>
167 167
 			</span>
168
-			<?php else: ?>
168
+			<?php else {
169
+    : ?>
169 170
 				<span class="status error"></span>
170
-				<span class="crondate" title="<?php p($absolute_time);?>">
171
+				<span class="crondate" title="<?php p($absolute_time);
172
+}
173
+?>">
171 174
 				<?php p($l->t("Last job execution ran %s. Something seems wrong.", [$relative_time]));?>
172 175
 			</span>
173 176
 			<?php endif;
174
-		else: ?>
177
+		else {
178
+		    : ?>
175 179
 			<span class="status error"></span>
176 180
 			<?php p($l->t("Background job didn’t run yet!"));
181
+		}
177 182
 		endif; ?>
178 183
 	</p>
179 184
 	<a target="_blank" rel="noreferrer noopener" class="icon-info"
Please login to merge, or discard this patch.
lib/private/Avatar.php 1 patch
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -230,7 +230,7 @@
 block discarded – undo
230 230
 			$r = $l;
231 231
 			$g = $l;
232 232
 			$b = $l; // achromatic
233
-		}else{
233
+		} else{
234 234
 			$q = $l < 0.5 ? $l * (1 + $s) : $l + $s - $l * $s;
235 235
 			$p = 2 * $l - $q;
236 236
 			$r = $hue2rgb($p, $q, $h + 1/3);
Please login to merge, or discard this patch.
apps/files_external/templates/settings.php 1 patch
Braces   +24 added lines, -6 removed lines patch added patch discarded remove patch
@@ -89,7 +89,10 @@  discard block
 block discarded – undo
89 89
 
90 90
 <form data-can-create="<?php echo $canCreateMounts?'true':'false' ?>" id="files_external" class="section" data-encryption-enabled="<?php echo $_['encryptionEnabled']?'true': 'false'; ?>">
91 91
 	<h2 data-anchor-name="external-storage"><?php p($l->t('External storages')); ?></h2>
92
-	<?php if (isset($_['dependencies']) and ($_['dependencies'] !== '') and $canCreateMounts) print_unescaped(''.$_['dependencies'].''); ?>
92
+	<?php if (isset($_['dependencies']) and ($_['dependencies'] !== '') and $canCreateMounts) {
93
+    print_unescaped(''.$_['dependencies'].'');
94
+}
95
+?>
93 96
 	<table id="externalStorage" class="grid" data-admin='<?php print_unescaped(json_encode($_['visibilityType'] === BackendService::VISIBILITY_ADMIN)); ?>'>
94 97
 		<thead>
95 98
 			<tr>
@@ -98,7 +101,10 @@  discard block
 block discarded – undo
98 101
 				<th><?php p($l->t('External storage')); ?></th>
99 102
 				<th><?php p($l->t('Authentication')); ?></th>
100 103
 				<th><?php p($l->t('Configuration')); ?></th>
101
-				<?php if ($_['visibilityType'] === BackendService::VISIBILITY_ADMIN) print_unescaped('<th>'.$l->t('Available for').'</th>'); ?>
104
+				<?php if ($_['visibilityType'] === BackendService::VISIBILITY_ADMIN) {
105
+    print_unescaped('<th>'.$l->t('Available for').'</th>');
106
+}
107
+?>
102 108
 				<th>&nbsp;</th>
103 109
 				<th>&nbsp;</th>
104 110
 			</tr>
@@ -130,7 +136,10 @@  discard block
 block discarded – undo
130 136
 							});
131 137
 						?>
132 138
 						<?php foreach ($sortedBackends as $backend): ?>
133
-							<?php if ($backend->getDeprecateTo()) continue; // ignore deprecated backends ?>
139
+							<?php if ($backend->getDeprecateTo()) {
140
+    continue;
141
+}
142
+// ignore deprecated backends ?>
134 143
 							<option value="<?php p($backend->getIdentifier()); ?>"><?php p($backend->getText()); ?></option>
135 144
 						<?php endforeach; ?>
136 145
 					</select>
@@ -169,7 +178,10 @@  discard block
 block discarded – undo
169 178
 
170 179
 	<?php if ($_['visibilityType'] === BackendService::VISIBILITY_ADMIN): ?>
171 180
 		<input type="checkbox" name="allowUserMounting" id="allowUserMounting" class="checkbox"
172
-			value="1" <?php if ($_['allowUserMounting']) print_unescaped(' checked="checked"'); ?> />
181
+			value="1" <?php if ($_['allowUserMounting']) {
182
+    print_unescaped(' checked="checked"');
183
+}
184
+?> />
173 185
 		<label for="allowUserMounting"><?php p($l->t('Allow users to mount external storage')); ?></label> <span id="userMountingMsg" class="msg"></span>
174 186
 
175 187
 		<p id="userMountingBackends"<?php if (!$_['allowUserMounting']): ?> class="hidden"<?php endif; ?>>
@@ -182,8 +194,14 @@  discard block
 block discarded – undo
182 194
 			<?php $i = 0; foreach ($userBackends as $backend): ?>
183 195
 				<?php if ($deprecateTo = $backend->getDeprecateTo()): ?>
184 196
 					<input type="hidden" id="allowUserMountingBackends<?php p($i); ?>" name="allowUserMountingBackends[]" value="<?php p($backend->getIdentifier()); ?>" data-deprecate-to="<?php p($deprecateTo->getIdentifier()); ?>" />
185
-				<?php else: ?>
186
-					<input type="checkbox" id="allowUserMountingBackends<?php p($i); ?>" class="checkbox" name="allowUserMountingBackends[]" value="<?php p($backend->getIdentifier()); ?>" <?php if ($backend->isVisibleFor(BackendService::VISIBILITY_PERSONAL)) print_unescaped(' checked="checked"'); ?> />
197
+				<?php else {
198
+    : ?>
199
+					<input type="checkbox" id="allowUserMountingBackends<?php p($i);
200
+}
201
+?>" class="checkbox" name="allowUserMountingBackends[]" value="<?php p($backend->getIdentifier()); ?>" <?php if ($backend->isVisibleFor(BackendService::VISIBILITY_PERSONAL)) {
202
+    print_unescaped(' checked="checked"');
203
+}
204
+?> />
187 205
 					<label for="allowUserMountingBackends<?php p($i); ?>"><?php p($backend->getText()); ?></label> <br />
188 206
 				<?php endif; ?>
189 207
 				<?php $i++; ?>
Please login to merge, or discard this patch.
lib/private/Setup/MySQL.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -103,8 +103,7 @@
 block discarded – undo
103 103
 			$connection->executeUpdate($query);
104 104
 			$query = "CREATE USER '$name'@'%' IDENTIFIED BY '$password'";
105 105
 			$connection->executeUpdate($query);
106
-		}
107
-		catch (\Exception $ex){
106
+		} catch (\Exception $ex){
108 107
 			$this->logger->logException($ex, [
109 108
 				'message' => 'Database user creation failed.',
110 109
 				'level' => \OCP\Util::ERROR,
Please login to merge, or discard this patch.
apps/files_sharing/templates/public.php 1 patch
Braces   +10 added lines, -4 removed lines patch added patch discarded remove patch
@@ -90,17 +90,23 @@
 block discarded – undo
90 90
 	<div id="preview">
91 91
 			<?php if (isset($_['folder'])): ?>
92 92
 				<?php print_unescaped($_['folder']); ?>
93
-			<?php else: ?>
93
+			<?php else {
94
+    : ?>
94 95
 				<?php if ($_['previewEnabled'] && substr($_['mimetype'], 0, strpos($_['mimetype'], '/')) == 'audio'): ?>
95 96
 					<div id="imgframe">
96
-						<audio tabindex="0" controls="" preload="none" style="width: 100%; max-width: <?php p($_['previewMaxX']); ?>px; max-height: <?php p($_['previewMaxY']); ?>px">
97
+						<audio tabindex="0" controls="" preload="none" style="width: 100%; max-width: <?php p($_['previewMaxX']);
98
+}
99
+?>px; max-height: <?php p($_['previewMaxY']); ?>px">
97 100
 							<source src="<?php p($_['downloadURL']); ?>" type="<?php p($_['mimetype']); ?>" />
98 101
 						</audio>
99 102
 					</div>
100
-				<?php else: ?>
103
+				<?php else {
104
+    : ?>
101 105
 					<!-- Preview frame is filled via JS to support SVG images for modern browsers -->
102 106
 					<div id="imgframe"></div>
103
-				<?php endif; ?>
107
+				<?php endif;
108
+}
109
+?>
104 110
 				<?php if ($_['previewURL'] === $_['downloadURL']): ?>
105 111
 				<div class="directDownload">
106 112
 					<a href="<?php p($_['downloadURL']); ?>" id="downloadFile" class="button">
Please login to merge, or discard this patch.
apps/files_external/lib/Lib/Storage/OwnCloud.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -62,8 +62,7 @@
 block discarded – undo
62 62
 
63 63
 		if (isset($params['root'])){
64 64
 			$root = '/' . ltrim($params['root'], '/');
65
-		}
66
-		else{
65
+		} else{
67 66
 			$root = '/';
68 67
 		}
69 68
 
Please login to merge, or discard this patch.
settings/templates/settings/personal/personal.info.php 1 patch
Braces   +53 added lines, -17 removed lines patch added patch discarded remove patch
@@ -46,9 +46,12 @@  discard block
 block discarded – undo
46 46
 			<?php if ($_['quota'] === \OCP\Files\FileInfo::SPACE_UNLIMITED): ?>
47 47
 				<?php print_unescaped($l->t('You are using <strong>%s</strong> of <strong>%s</strong>',
48 48
 					[$_['usage'], $_['total_space']]));?>
49
-			<?php else: ?>
49
+			<?php else {
50
+    : ?>
50 51
 				<?php print_unescaped($l->t('You are using <strong>%s</strong> of <strong>%s</strong> (<strong>%s %%</strong>)',
51
-					[$_['usage'], $_['total_space'],  $_['usage_relative']]));?>
52
+					[$_['usage'], $_['total_space'],  $_['usage_relative']]));
53
+}
54
+?>
52 55
 			<?php endif ?>
53 56
 		</p>
54 57
 	</div>
@@ -57,9 +60,12 @@  discard block
 block discarded – undo
57 60
 			<?php if ($_['quota'] === \OCP\Files\FileInfo::SPACE_UNLIMITED): ?>
58 61
 				<?php print_unescaped($l->t('You are using <strong>%s</strong> of <strong>%s</strong>',
59 62
 					[$_['usage'], $_['total_space']]));?>
60
-			<?php else: ?>
63
+			<?php else {
64
+    : ?>
61 65
 				<?php print_unescaped($l->t('You are using <strong>%s</strong> of <strong>%s</strong> (<strong>%s %%</strong>)',
62
-					[$_['usage'], $_['total_space'],  $_['usage_relative']]));?>
66
+					[$_['usage'], $_['total_space'],  $_['usage_relative']]));
67
+}
68
+?>
63 69
 			<?php endif ?>
64 70
 		</p>
65 71
 	</div>
@@ -83,8 +89,11 @@  discard block
 block discarded – undo
83 89
 						<div class="hidden button icon-delete svg" id="removeavatar" title="<?php p($l->t('Remove image')); ?>"></div>
84 90
 						<input type="file" name="files[]" id="uploadavatar" class="hiddenuploadfield">
85 91
 						<p><em><?php p($l->t('png or jpg, max. 20 MB')); ?></em></p>
86
-					<?php else: ?>
87
-						<?php p($l->t('Picture provided by original account')); ?>
92
+					<?php else {
93
+    : ?>
94
+						<?php p($l->t('Picture provided by original account'));
95
+}
96
+?>
88 97
 					<?php endif; ?>
89 98
 				</div>
90 99
 
@@ -133,7 +142,10 @@  discard block
 block discarded – undo
133 142
 						<span class="icon-triangle-s"></span>
134 143
 					</span>
135 144
 				</h2>
136
-				<div class="verify <?php if ($_['email'] === ''  || $_['emailScope'] !== 'public') p('hidden'); ?>">
145
+				<div class="verify <?php if ($_['email'] === ''  || $_['emailScope'] !== 'public') {
146
+    p('hidden');
147
+}
148
+?>">
137 149
 					<img id="verify-email" title="<?php p($_['emailMessage']); ?>" data-status="<?php p($_['emailVerification']) ?>" src="
138 150
 				<?php
139 151
 					switch($_['emailVerification']) {
@@ -174,7 +186,10 @@  discard block
 block discarded – undo
174 186
 						<span class="icon-triangle-s"></span>
175 187
 					</span>
176 188
 				</h2>
177
-				<input type="tel" id="phone" name="phone" <?php if(!$_['lookupServerUploadEnabled']) print_unescaped('disabled="1"'); ?>
189
+				<input type="tel" id="phone" name="phone" <?php if(!$_['lookupServerUploadEnabled']) {
190
+    print_unescaped('disabled="1"');
191
+}
192
+?>
178 193
 					   value="<?php p($_['phone']) ?>"
179 194
 					   placeholder="<?php p($l->t('Your phone number')); ?>"
180 195
 				       autocomplete="on" autocapitalize="none" autocorrect="off" />
@@ -194,7 +209,10 @@  discard block
 block discarded – undo
194 209
 						<span class="icon-triangle-s"></span>
195 210
 					</span>
196 211
 				</h2>
197
-				<input type="text" id="address" name="address" <?php if(!$_['lookupServerUploadEnabled']) print_unescaped('disabled="1"');  ?>
212
+				<input type="text" id="address" name="address" <?php if(!$_['lookupServerUploadEnabled']) {
213
+    print_unescaped('disabled="1"');
214
+}
215
+?>
198 216
 					   placeholder="<?php p($l->t('Your postal address')); ?>"
199 217
 					   value="<?php p($_['address']) ?>"
200 218
 					   autocomplete="on" autocapitalize="none" autocorrect="off" />
@@ -215,7 +233,10 @@  discard block
 block discarded – undo
215 233
 					</span>
216 234
 				</h2>
217 235
 				<?php if($_['lookupServerUploadEnabled']) { ?>
218
-				<div class="verify <?php if ($_['website'] === ''  || $_['websiteScope'] !== 'public') p('hidden'); ?>">
236
+				<div class="verify <?php if ($_['website'] === ''  || $_['websiteScope'] !== 'public') {
237
+    p('hidden');
238
+}
239
+?>">
219 240
 					<img id="verify-website" title="<?php p($_['websiteMessage']); ?>" data-status="<?php p($_['websiteVerification']) ?>" src="
220 241
 					<?php
221 242
 					switch($_['websiteVerification']) {
@@ -229,13 +250,16 @@  discard block
 block discarded – undo
229 250
 							p(image_path('core', 'actions/verify.svg'));
230 251
 					}
231 252
 					?>"
232
-					<?php if($_['websiteVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['websiteVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) print_unescaped(' class="verify-action"') ?>
253
+					<?php if($_['websiteVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['websiteVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) {
254
+    print_unescaped(' class="verify-action"') ?>
233 255
 					>
234 256
 					<div class="verification-dialog popovermenu bubble menu">
235 257
 						<div class="verification-dialog-content">
236 258
 							<p class="explainVerification"></p>
237 259
 							<p class="verificationCode"></p>
238
-							<p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.'));?></p>
260
+							<p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.'));
261
+}
262
+?></p>
239 263
 						</div>
240 264
 					</div>
241 265
 				</div>
@@ -243,7 +267,10 @@  discard block
 block discarded – undo
243 267
 				<input type="url" name="website" id="website" value="<?php p($_['website']); ?>"
244 268
 				       placeholder="<?php p($l->t('Link https://…')); ?>"
245 269
 				       autocomplete="on" autocapitalize="none" autocorrect="off"
246
-					   <?php if(!$_['lookupServerUploadEnabled']) print_unescaped('disabled="1"');  ?>
270
+					   <?php if(!$_['lookupServerUploadEnabled']) {
271
+    print_unescaped('disabled="1"');
272
+}
273
+?>
247 274
 				/>
248 275
 				<span class="icon-checkmark hidden"></span>
249 276
 				<?php if($_['lookupServerUploadEnabled']) { ?>
@@ -262,7 +289,10 @@  discard block
 block discarded – undo
262 289
 					</span>
263 290
 				</h2>
264 291
 				<?php if($_['lookupServerUploadEnabled']) { ?>
265
-				<div class="verify <?php if ($_['twitter'] === ''  || $_['twitterScope'] !== 'public') p('hidden'); ?>">
292
+				<div class="verify <?php if ($_['twitter'] === ''  || $_['twitterScope'] !== 'public') {
293
+    p('hidden');
294
+}
295
+?>">
266 296
 					<img id="verify-twitter" title="<?php p($_['twitterMessage']); ?>" data-status="<?php p($_['twitterVerification']) ?>" src="
267 297
 					<?php
268 298
 					switch($_['twitterVerification']) {
@@ -276,13 +306,16 @@  discard block
 block discarded – undo
276 306
 							p(image_path('core', 'actions/verify.svg'));
277 307
 					}
278 308
 					?>"
279
-					<?php if($_['twitterVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['twitterVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) print_unescaped(' class="verify-action"') ?>
309
+					<?php if($_['twitterVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['twitterVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) {
310
+    print_unescaped(' class="verify-action"') ?>
280 311
 					>
281 312
 					<div class="verification-dialog popovermenu bubble menu">
282 313
 						<div class="verification-dialog-content">
283 314
 							<p class="explainVerification"></p>
284 315
 							<p class="verificationCode"></p>
285
-							<p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.'));?></p>
316
+							<p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.'));
317
+}
318
+?></p>
286 319
 						</div>
287 320
 					</div>
288 321
 				</div>
@@ -290,7 +323,10 @@  discard block
 block discarded – undo
290 323
 				<input type="text" name="twitter" id="twitter" value="<?php p($_['twitter']); ?>"
291 324
 					   placeholder="<?php p($l->t('Twitter handle @…')); ?>"
292 325
 					   autocomplete="on" autocapitalize="none" autocorrect="off"
293
-					   <?php if(!$_['lookupServerUploadEnabled']) print_unescaped('disabled="1"');  ?>
326
+					   <?php if(!$_['lookupServerUploadEnabled']) {
327
+    print_unescaped('disabled="1"');
328
+}
329
+?>
294 330
 				/>
295 331
 				<span class="icon-checkmark hidden"></span>
296 332
 				<?php if($_['lookupServerUploadEnabled']) { ?>
Please login to merge, or discard this patch.
lib/private/legacy/response.php 1 patch
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -53,13 +53,11 @@  discard block
 block discarded – undo
53 53
 			if ($cache_time > 0) {
54 54
 				self::setExpiresHeader('PT'.$cache_time.'S');
55 55
 				header('Cache-Control: max-age='.$cache_time.', must-revalidate');
56
-			}
57
-			else {
56
+			} else {
58 57
 				header('Expires: 0');
59 58
 				header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
60 59
 			}
61
-		}
62
-		else {
60
+		} else {
63 61
 			header('Cache-Control: cache');
64 62
 			header('Pragma: cache');
65 63
 		}
@@ -222,8 +220,7 @@  discard block
 block discarded – undo
222 220
 
223 221
 			self::setContentLengthHeader(filesize($filepath));
224 222
 			fpassthru($fp);
225
-		}
226
-		else {
223
+		} else {
227 224
 			self::setStatus(self::STATUS_NOT_FOUND);
228 225
 		}
229 226
 	}
Please login to merge, or discard this patch.