Completed
Pull Request — master (#9029)
by Julius
15:57
created
settings/templates/settings/admin/overview.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -27,8 +27,8 @@  discard block
 block discarded – undo
27 27
 ?>
28 28
 
29 29
 <div id="security-warning" class="section">
30
-	<h2><?php p($l->t('Security & setup warnings'));?></h2>
31
-	<p class="settings-hint"><?php p($l->t('It\'s important for the security and performance of your instance that everything is configured correctly. To help you with that we are doing some automatic checks. Please see the Tips & Tricks section and the documentation for more information.'));?></p>
30
+	<h2><?php p($l->t('Security & setup warnings')); ?></h2>
31
+	<p class="settings-hint"><?php p($l->t('It\'s important for the security and performance of your instance that everything is configured correctly. To help you with that we are doing some automatic checks. Please see the Tips & Tricks section and the documentation for more information.')); ?></p>
32 32
 	<ul>
33 33
 		<?php
34 34
 		// is php setup properly to query system environment variables like getenv('PATH')
@@ -130,7 +130,7 @@  discard block
 block discarded – undo
130 130
 				<?php p($l->t('It was not possible to execute the cron job via CLI. The following technical errors have appeared:')); ?>
131 131
 				<br>
132 132
 				<ol>
133
-					<?php foreach(json_decode($_['cronErrors']) as $error) { if(isset($error->error)) {?>
133
+					<?php foreach (json_decode($_['cronErrors']) as $error) { if (isset($error->error)) {?>
134 134
 						<li><?php p($error->error) ?> <?php p($error->hint) ?></li>
135 135
 					<?php }} ?>
136 136
 				</ol>
@@ -143,30 +143,30 @@  discard block
 block discarded – undo
143 143
 				$formatter = \OC::$server->getDateTimeFormatter();
144 144
 				$absolute_time = $formatter->formatDateTime($_['lastcron'], 'long', 'long');
145 145
 				if (time() - $_['lastcron'] > 3600): ?>
146
-					<li class="crondate" title="<?php p($absolute_time);?>">
147
-						<?php p($l->t("Last background job execution ran %s. Something seems wrong.", [$relative_time]));?>
146
+					<li class="crondate" title="<?php p($absolute_time); ?>">
147
+						<?php p($l->t("Last background job execution ran %s. Something seems wrong.", [$relative_time])); ?>
148 148
 						<a href="<?php p(\OC::$server->getURLGenerator()->linkToRoute('settings.AdminSettings.index', ['section' => 'server'])); ?>#backgroundjobs"><?php p($l->t('Check the background job settings')); ?></a>
149 149
 					</li>
150 150
 				<?php endif; ?>
151 151
 			<?php endif; ?>
152 152
 	</ul>
153 153
 
154
-	<div id="postsetupchecks" data-check-wellknown="<?php if($_['checkForWorkingWellKnownSetup']) { p('true'); } else { p('false'); } ?>">
154
+	<div id="postsetupchecks" data-check-wellknown="<?php if ($_['checkForWorkingWellKnownSetup']) { p('true'); } else { p('false'); } ?>">
155 155
 		<div class="loading"></div>
156 156
 		<ul class="errors hidden"></ul>
157 157
 		<ul class="warnings hidden"></ul>
158 158
 		<ul class="info hidden"></ul>
159 159
 		<p class="hint hidden">
160
-			<?php print_unescaped($l->t('Please double check the <a target="_blank" rel="noreferrer noopener" href="%s">installation guides ↗</a>, and check for any errors or warnings in the <a href="%s">log</a>.', [link_to_docs('admin-install'), \OC::$server->getURLGenerator()->linkToRoute('settings.AdminSettings.index', ['section' => 'logging'])] )); ?>
160
+			<?php print_unescaped($l->t('Please double check the <a target="_blank" rel="noreferrer noopener" href="%s">installation guides ↗</a>, and check for any errors or warnings in the <a href="%s">log</a>.', [link_to_docs('admin-install'), \OC::$server->getURLGenerator()->linkToRoute('settings.AdminSettings.index', ['section' => 'logging'])])); ?>
161 161
 		</p>
162 162
 	</div>
163 163
 	<div id="security-warning-state">
164
-		<span class="hidden icon-checkmark"><?php p($l->t('All checks passed.'));?></span>
164
+		<span class="hidden icon-checkmark"><?php p($l->t('All checks passed.')); ?></span>
165 165
 	</div>
166 166
 </div>
167 167
 
168 168
 <div class="section">
169 169
 	<!-- should be the last part, so Updater can follow if enabled (it has no heading therefore). -->
170
-	<h2><?php p($l->t('Version'));?></h2>
170
+	<h2><?php p($l->t('Version')); ?></h2>
171 171
 	<p><strong><a href="<?php print_unescaped($theme->getBaseUrl()); ?>" rel="noreferrer noopener" target="_blank"><?php p($theme->getTitle()); ?></a> <?php p(OC_Util::getHumanVersion()) ?></strong></p>
172 172
 </div>
Please login to merge, or discard this patch.
settings/templates/settings/admin/server.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
 ?>
28 28
 
29 29
 <div class="section" id="backgroundjobs">
30
-	<h2 class="inlineblock"><?php p($l->t('Background jobs'));?></h2>
30
+	<h2 class="inlineblock"><?php p($l->t('Background jobs')); ?></h2>
31 31
 	<p class="cronlog inlineblock">
32 32
 		<?php if ($_['lastcron'] !== false):
33 33
 			$relative_time = relative_modified_date($_['lastcron']);
@@ -36,13 +36,13 @@  discard block
 block discarded – undo
36 36
 			$absolute_time = $formatter->formatDateTime($_['lastcron'], 'long', 'long');
37 37
 			if (time() - $_['lastcron'] <= 3600): ?>
38 38
 				<span class="status success"></span>
39
-				<span class="crondate" title="<?php p($absolute_time);?>">
40
-				<?php p($l->t("Last job ran %s.", [$relative_time]));?>
39
+				<span class="crondate" title="<?php p($absolute_time); ?>">
40
+				<?php p($l->t("Last job ran %s.", [$relative_time])); ?>
41 41
 			</span>
42 42
 			<?php else: ?>
43 43
 				<span class="status error"></span>
44
-				<span class="crondate" title="<?php p($absolute_time);?>">
45
-				<?php p($l->t("Last job execution ran %s. Something seems wrong.", [$relative_time]));?>
44
+				<span class="crondate" title="<?php p($absolute_time); ?>">
45
+				<?php p($l->t("Last job execution ran %s. Something seems wrong.", [$relative_time])); ?>
46 46
 			</span>
47 47
 			<?php endif;
48 48
 		else: ?>
@@ -51,10 +51,10 @@  discard block
 block discarded – undo
51 51
 		endif; ?>
52 52
 	</p>
53 53
 	<a target="_blank" rel="noreferrer noopener" class="icon-info"
54
-	   title="<?php p($l->t('Open documentation'));?>"
54
+	   title="<?php p($l->t('Open documentation')); ?>"
55 55
 	   href="<?php p(link_to_docs('admin-background-jobs')); ?>"></a>
56 56
 
57
-	<p class="settings-hint"><?php p($l->t('For optimal performance it\'s important to configure background jobs correctly. For bigger instances \'Cron\' is the recommended setting. Please see the documentation for more information.'));?></p>
57
+	<p class="settings-hint"><?php p($l->t('For optimal performance it\'s important to configure background jobs correctly. For bigger instances \'Cron\' is the recommended setting. Please see the documentation for more information.')); ?></p>
58 58
 	<p>
59 59
 		<input type="radio" name="mode" value="ajax" class="radio"
60 60
 			   id="backgroundjobs_ajax" <?php if ($_['backgroundjobs_mode'] === "ajax") {
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
 		}?>>
82 82
 		<label for="backgroundjobs_cron">Cron</label><br/>
83 83
 		<em><?php p($l->t("Use system cron service to call the cron.php file every 15 minutes.")); ?>
84
-			<?php if($_['cli_based_cron_possible']) {
84
+			<?php if ($_['cli_based_cron_possible']) {
85 85
 				p($l->t('The cron.php needs to be executed by the system user "%s".', [$_['cli_based_cron_user']]));
86 86
 			} else {
87 87
 				print_unescaped(str_replace(
Please login to merge, or discard this patch.
apps/federatedfilesharing/templates/settings-admin.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -4,13 +4,13 @@  discard block
 block discarded – undo
4 4
 script('federatedfilesharing', 'settings-admin');
5 5
 ?>
6 6
 
7
-<?php if($_['internalOnly'] === false): ?>
7
+<?php if ($_['internalOnly'] === false): ?>
8 8
 
9 9
 <div id="fileSharingSettings" class="section">
10 10
 	<h2>
11
-		<?php p($l->t('Federated Cloud Sharing'));?>
11
+		<?php p($l->t('Federated Cloud Sharing')); ?>
12 12
 		<a target="_blank" rel="noreferrer noopener" class="icon-info svg"
13
-		   title="<?php p($l->t('Open documentation'));?>"
13
+		   title="<?php p($l->t('Open documentation')); ?>"
14 14
 		   href="<?php p(link_to_docs('admin-sharing-federated')); ?>"></a>
15 15
 	</h2>
16 16
 
@@ -20,7 +20,7 @@  discard block
 block discarded – undo
20 20
 		<input type="checkbox" name="outgoing_server2server_share_enabled" id="outgoingServer2serverShareEnabled" class="checkbox"
21 21
 			   value="1" <?php if ($_['outgoingServer2serverShareEnabled']) print_unescaped('checked="checked"'); ?> />
22 22
 		<label for="outgoingServer2serverShareEnabled">
23
-			<?php p($l->t('Allow users on this server to send shares to other servers'));?>
23
+			<?php p($l->t('Allow users on this server to send shares to other servers')); ?>
24 24
 		</label>
25 25
 	</p>
26 26
 
@@ -28,21 +28,21 @@  discard block
 block discarded – undo
28 28
 		<input type="checkbox" name="incoming_server2server_share_enabled" id="incomingServer2serverShareEnabled" class="checkbox"
29 29
 			   value="1" <?php if ($_['incomingServer2serverShareEnabled']) print_unescaped('checked="checked"'); ?> />
30 30
 		<label for="incomingServer2serverShareEnabled">
31
-			<?php p($l->t('Allow users on this server to receive shares from other servers'));?>
31
+			<?php p($l->t('Allow users on this server to receive shares from other servers')); ?>
32 32
 		</label><br/>
33 33
 	</p>
34 34
 	<p>
35 35
 		<input type="checkbox" name="lookupServerEnabled" id="lookupServerEnabled" class="checkbox"
36 36
 			   value="1" <?php if ($_['lookupServerEnabled']) print_unescaped('checked="checked"'); ?> />
37 37
 		<label for="lookupServerEnabled">
38
-			<?php p($l->t('Search global and public address book for users'));?>
38
+			<?php p($l->t('Search global and public address book for users')); ?>
39 39
 		</label><br/>
40 40
 	</p>
41 41
 	<p>
42 42
 		<input type="checkbox" name="lookupServerUploadEnabled" id="lookupServerUploadEnabled" class="checkbox"
43 43
 			   value="1" <?php if ($_['lookupServerUploadEnabled']) print_unescaped('checked="checked"'); ?> />
44 44
 		<label for="lookupServerUploadEnabled">
45
-			<?php p($l->t('Allow users to publish their data to a global and public address book'));?>
45
+			<?php p($l->t('Allow users to publish their data to a global and public address book')); ?>
46 46
 		</label><br/>
47 47
 	</p>
48 48
 
Please login to merge, or discard this patch.
settings/Controller/CommonSettingsTrait.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
 use OCP\Settings\IIconSection;
31 31
 use OCP\Settings\ISettings;
32 32
 
33
-trait CommonSettingsTrait  {
33
+trait CommonSettingsTrait {
34 34
 	/** @var ISettingsManager */
35 35
 	private $settingsManager;
36 36
 
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 			'admin' => []
48 48
 		];
49 49
 
50
-		if(\OC_User::isAdminUser(\OC_User::getUser())) {
50
+		if (\OC_User::isAdminUser(\OC_User::getUser())) {
51 51
 			$templateParameters['admin'] = $this->formatAdminSections($currentType, $currentSection);
52 52
 		}
53 53
 
@@ -59,11 +59,11 @@  discard block
 block discarded – undo
59 59
 	protected function formatSections($sections, $currentSection, $type, $currentType) {
60 60
 		$templateParameters = [];
61 61
 		/** @var \OCP\Settings\ISection[] $prioritizedSections */
62
-		foreach($sections as $prioritizedSections) {
62
+		foreach ($sections as $prioritizedSections) {
63 63
 			foreach ($prioritizedSections as $section) {
64
-				if($type === 'admin') {
64
+				if ($type === 'admin') {
65 65
 					$settings = $this->settingsManager->getAdminSettings($section->getID());
66
-				} else if($type === 'personal') {
66
+				} else if ($type === 'personal') {
67 67
 					$settings = $this->settingsManager->getPersonalSettings($section->getID());
68 68
 				}
69 69
 				if (empty($settings) && !($section->getID() === 'additional' && count(\OC_App::getForms('admin')) > 0)) {
Please login to merge, or discard this patch.
lib/private/Settings/Admin/Overview.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -107,7 +107,7 @@
 block discarded – undo
107 107
 
108 108
 		$suggestedOverwriteCliUrl = '';
109 109
 		if ($this->config->getSystemValue('overwrite.cli.url', '') === '') {
110
-			$suggestedOverwriteCliUrl = $this->request->getServerProtocol() . '://' . $this->request->getInsecureServerHost() . \OC::$WEBROOT;
110
+			$suggestedOverwriteCliUrl = $this->request->getServerProtocol().'://'.$this->request->getInsecureServerHost().\OC::$WEBROOT;
111 111
 			if (!$this->config->getSystemValue('config_is_read_only', false)) {
112 112
 				// Set the overwrite URL when it was not set yet.
113 113
 				$this->config->setSystemValue('overwrite.cli.url', $suggestedOverwriteCliUrl);
Please login to merge, or discard this patch.
lib/private/Settings/Admin/Server.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@
 block discarded – undo
80 80
 			'lastcron'            => $this->config->getAppValue('core', 'lastcron', false),
81 81
 			'cronErrors'		  => $this->config->getAppValue('core', 'cronErrors'),
82 82
 			'cli_based_cron_possible' => function_exists('posix_getpwuid'),
83
-			'cli_based_cron_user' => function_exists('posix_getpwuid') ? posix_getpwuid(fileowner(\OC::$configDir . 'config.php'))['name'] : '',
83
+			'cli_based_cron_user' => function_exists('posix_getpwuid') ? posix_getpwuid(fileowner(\OC::$configDir.'config.php'))['name'] : '',
84 84
 		];
85 85
 
86 86
 		return new TemplateResponse('settings', 'settings/admin/server', $parameters, '');
Please login to merge, or discard this patch.