Passed
Push — master ( 1d8da4...323fe4 )
by Roeland
09:56 queued 10s
created
remote.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
  *
29 29
  */
30 30
 
31
-require_once __DIR__ . '/lib/versioncheck.php';
31
+require_once __DIR__.'/lib/versioncheck.php';
32 32
 
33 33
 use OCA\DAV\Connector\Sabre\ExceptionLoggerPlugin;
34 34
 use Sabre\DAV\Exception\ServiceUnavailable;
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
 			// we shall not log on RemoteException
57 57
 			$server->addPlugin(new ExceptionLoggerPlugin('webdav', \OC::$server->getLogger()));
58 58
 		}
59
-		$server->on('beforeMethod', function () use ($e) {
59
+		$server->on('beforeMethod', function() use ($e) {
60 60
 			if ($e instanceof RemoteException) {
61 61
 				switch ($e->getCode()) {
62 62
 					case 503:
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
 		$server->exec();
73 73
 	} else {
74 74
 		$statusCode = 500;
75
-		if ($e instanceof \OC\ServiceUnavailableException ) {
75
+		if ($e instanceof \OC\ServiceUnavailableException) {
76 76
 			$statusCode = 503;
77 77
 		}
78 78
 		if ($e instanceof RemoteException) {
@@ -104,11 +104,11 @@  discard block
 block discarded – undo
104 104
 		return $services[$service];
105 105
 	}
106 106
 
107
-	return \OC::$server->getConfig()->getAppValue('core', 'remote_' . $service);
107
+	return \OC::$server->getConfig()->getAppValue('core', 'remote_'.$service);
108 108
 }
109 109
 
110 110
 try {
111
-	require_once __DIR__ . '/lib/base.php';
111
+	require_once __DIR__.'/lib/base.php';
112 112
 
113 113
 	// All resources served via the DAV endpoint should have the strictest possible
114 114
 	// policy. Exempted from this is the SabreDAV browser plugin which overwrites
@@ -129,18 +129,18 @@  discard block
 block discarded – undo
129 129
 	if (!$pos = strpos($pathInfo, '/', 1)) {
130 130
 		$pos = strlen($pathInfo);
131 131
 	}
132
-	$service=substr($pathInfo, 1, $pos-1);
132
+	$service = substr($pathInfo, 1, $pos - 1);
133 133
 
134 134
 	$file = resolveService($service);
135 135
 
136
-	if(is_null($file)) {
136
+	if (is_null($file)) {
137 137
 		throw new RemoteException('Path not found', 404);
138 138
 	}
139 139
 
140
-	$file=ltrim($file, '/');
140
+	$file = ltrim($file, '/');
141 141
 
142
-	$parts=explode('/', $file, 2);
143
-	$app=$parts[0];
142
+	$parts = explode('/', $file, 2);
143
+	$app = $parts[0];
144 144
 
145 145
 	// Load all required applications
146 146
 	\OC::$REQUESTEDAPP = $app;
@@ -149,17 +149,17 @@  discard block
 block discarded – undo
149 149
 
150 150
 	switch ($app) {
151 151
 		case 'core':
152
-			$file =  OC::$SERVERROOT .'/'. $file;
152
+			$file = OC::$SERVERROOT.'/'.$file;
153 153
 			break;
154 154
 		default:
155 155
 			if (!\OC::$server->getAppManager()->isInstalled($app)) {
156
-				throw new RemoteException('App not installed: ' . $app);
156
+				throw new RemoteException('App not installed: '.$app);
157 157
 			}
158 158
 			OC_App::loadApp($app);
159
-			$file = OC_App::getAppPath($app) .'/'. $parts[1];
159
+			$file = OC_App::getAppPath($app).'/'.$parts[1];
160 160
 			break;
161 161
 	}
162
-	$baseuri = OC::$WEBROOT . '/remote.php/'.$service.'/';
162
+	$baseuri = OC::$WEBROOT.'/remote.php/'.$service.'/';
163 163
 	require_once $file;
164 164
 
165 165
 } catch (Exception $ex) {
Please login to merge, or discard this patch.
apps/dav/lib/Controller/InvitationResponseController.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -167,7 +167,7 @@  discard block
 block discarded – undo
167 167
 		$stmt = $query->execute();
168 168
 		$row = $stmt->fetch(\PDO::FETCH_ASSOC);
169 169
 
170
-		if(!$row) {
170
+		if (!$row) {
171 171
 			return null;
172 172
 		}
173 173
 
@@ -186,8 +186,8 @@  discard block
 block discarded – undo
186 186
 	 * @param string|null $comment
187 187
 	 * @return Message
188 188
 	 */
189
-	private function buildITipResponse(array $row, string $partStat, int $guests=null,
190
-									   string $comment=null):Message {
189
+	private function buildITipResponse(array $row, string $partStat, int $guests = null,
190
+									   string $comment = null):Message {
191 191
 		$iTipMessage = new Message();
192 192
 		$iTipMessage->uid = $row['uid'];
193 193
 		$iTipMessage->component = 'VEVENT';
Please login to merge, or discard this patch.
apps/dav/lib/CalDAV/InvitationResponse/InvitationResponseServer.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
 	 * InvitationResponseServer constructor.
41 41
 	 */
42 42
 	public function __construct() {
43
-		$baseUri = \OC::$WEBROOT . '/remote.php/dav/';
43
+		$baseUri = \OC::$WEBROOT.'/remote.php/dav/';
44 44
 		$logger = \OC::$server->getLogger();
45 45
 		$dispatcher = \OC::$server->getEventDispatcher();
46 46
 
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
 		));
92 92
 
93 93
 		// wait with registering these until auth is handled and the filesystem is setup
94
-		$this->server->on('beforeMethod', function () use ($root) {
94
+		$this->server->on('beforeMethod', function() use ($root) {
95 95
 			// register plugins from apps
96 96
 			$pluginManager = new PluginManager(
97 97
 				\OC::$server,
Please login to merge, or discard this patch.
apps/dav/templates/schedule-response-options.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
 			<input type="text" name="comment" placeholder="Comment" />
30 30
 		</fieldset>
31 31
 		<fieldset>
32
-			<input type="submit" value="<?php p($l->t('Save'));?>">
32
+			<input type="submit" value="<?php p($l->t('Save')); ?>">
33 33
 		</fieldset>
34 34
 	</form>
35 35
 </div>
Please login to merge, or discard this patch.
apps/dav/templates/schedule-response-error.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,7 +1,7 @@
 block discarded – undo
1 1
 <div class="update">
2
-	<p class="message"><?php p($l->t('There was an error updating your attendance status.'));?></p>
3
-	<p class="message"><?php p($l->t('Please contact the organizer directly.'));?></p>
4
-	<?php if(isset($_['organizer'])): ?>
2
+	<p class="message"><?php p($l->t('There was an error updating your attendance status.')); ?></p>
3
+	<p class="message"><?php p($l->t('Please contact the organizer directly.')); ?></p>
4
+	<?php if (isset($_['organizer'])): ?>
5 5
 		<p class="message"><a href="<?php p($_['organizer']) ?>"><?php p(substr($_['organizer'], 7)) ?></a></p>
6 6
 	<?php endif; ?>
7 7
 </div>
Please login to merge, or discard this patch.
apps/dav/templates/schedule-response-success.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1 1
 <div class="update" style="justify-content: space-around; display: flex;">
2 2
 	<span class="icon icon-checkmark-white"></span>
3
-	<p class="message"><?php p($l->t('Your attendance was updated successfully.'));?></p>
3
+	<p class="message"><?php p($l->t('Your attendance was updated successfully.')); ?></p>
4 4
 </div>
Please login to merge, or discard this patch.
lib/public/IL10N.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
 	 * @return string language
108 108
 	 * @since 7.0.0
109 109
 	 */
110
-	public function getLanguageCode(): string ;
110
+	public function getLanguageCode(): string;
111 111
 
112 112
 	/**
113 113
 	 * * The code (en_US, fr_CA, ...) of the locale that is used for this IL10N object
Please login to merge, or discard this patch.
apps/dav/appinfo/app.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
 		$job = $app->getContainer()->query(\OCA\DAV\BackgroundJob\UpdateCalendarResourcesRoomsBackgroundJob::class);
54 54
 		$job->run([]);
55 55
 		$app->getContainer()->getServer()->getJobList()->setLastRun($job);
56
-	} catch(\Exception $ex) {
56
+	} catch (\Exception $ex) {
57 57
 		$app->getContainer()->getServer()->getLogger()->logException($ex);
58 58
 	}
59 59
 };
Please login to merge, or discard this patch.
apps/dav/lib/Server.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
 		$authPlugin->addBackend($authBackend);
121 121
 
122 122
 		// debugging
123
-		if(\OC::$server->getConfig()->getSystemValue('debug', false)) {
123
+		if (\OC::$server->getConfig()->getSystemValue('debug', false)) {
124 124
 			$this->server->addPlugin(new \Sabre\DAV\Browser\Plugin());
125 125
 		} else {
126 126
 			$this->server->addPlugin(new DummyGetResponsePlugin());
@@ -184,10 +184,10 @@  discard block
 block discarded – undo
184 184
 
185 185
 		// Some WebDAV clients do require Class 2 WebDAV support (locking), since
186 186
 		// we do not provide locking we emulate it using a fake locking plugin.
187
-		if($request->isUserAgent([
187
+		if ($request->isUserAgent([
188 188
 			'/WebDAVFS/',
189 189
 			'/OneNote/',
190
-			'/^Microsoft-WebDAV/',// Microsoft-WebDAV-MiniRedir/6.1.7601
190
+			'/^Microsoft-WebDAV/', // Microsoft-WebDAV-MiniRedir/6.1.7601
191 191
 		])) {
192 192
 			$this->server->addPlugin(new FakeLockerPlugin());
193 193
 		}
@@ -200,7 +200,7 @@  discard block
 block discarded – undo
200 200
 		$this->server->addPlugin(new SearchPlugin($lazySearchBackend));
201 201
 
202 202
 		// wait with registering these until auth is handled and the filesystem is setup
203
-		$this->server->on('beforeMethod', function () use ($root, $lazySearchBackend) {
203
+		$this->server->on('beforeMethod', function() use ($root, $lazySearchBackend) {
204 204
 			// custom properties plugin must be the last one
205 205
 			$userSession = \OC::$server->getUserSession();
206 206
 			$user = $userSession->getUser();
Please login to merge, or discard this patch.