Passed
Push — master ( 7d5b0c...557c49 )
by Roeland
13:29 queued 12s
created
lib/private/legacy/db/statementwrapper.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -54,8 +54,8 @@  discard block
 block discarded – undo
54 54
 	/**
55 55
 	 * pass all other function directly to the \Doctrine\DBAL\Driver\Statement
56 56
 	 */
57
-	public function __call($name,$arguments) {
58
-		return call_user_func_array(array($this->statement,$name), $arguments);
57
+	public function __call($name, $arguments) {
58
+		return call_user_func_array(array($this->statement, $name), $arguments);
59 59
 	}
60 60
 
61 61
 	/**
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
 	 * @param array $input
65 65
 	 * @return \OC_DB_StatementWrapper|int|bool
66 66
 	 */
67
-	public function execute($input= []) {
67
+	public function execute($input = []) {
68 68
 		$this->lastArguments = $input;
69 69
 		if (count($input) > 0) {
70 70
 			$result = $this->statement->execute($input);
@@ -113,7 +113,7 @@  discard block
 block discarded – undo
113 113
 	 * @param integer|null $length max length when using an OUT bind
114 114
 	 * @return boolean
115 115
 	 */
116
-	public function bindParam($column, &$variable, $type = null, $length = null){
116
+	public function bindParam($column, &$variable, $type = null, $length = null) {
117 117
 		return $this->statement->bindParam($column, $variable, $type, $length);
118 118
 	}
119 119
 }
Please login to merge, or discard this patch.
lib/public/AppFramework/ApiController.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -59,9 +59,9 @@  discard block
 block discarded – undo
59 59
      */
60 60
     public function __construct($appName,
61 61
                                 IRequest $request,
62
-                                $corsMethods='PUT, POST, GET, DELETE, PATCH',
63
-                                $corsAllowedHeaders='Authorization, Content-Type, Accept',
64
-                                $corsMaxAge=1728000){
62
+                                $corsMethods = 'PUT, POST, GET, DELETE, PATCH',
63
+                                $corsAllowedHeaders = 'Authorization, Content-Type, Accept',
64
+                                $corsMaxAge = 1728000) {
65 65
         parent::__construct($appName, $request);
66 66
         $this->corsMethods = $corsMethods;
67 67
         $this->corsAllowedHeaders = $corsAllowedHeaders;
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
 	 * @since 7.0.0
80 80
      */
81 81
     public function preflightedCors() {
82
-        if(isset($this->request->server['HTTP_ORIGIN'])) {
82
+        if (isset($this->request->server['HTTP_ORIGIN'])) {
83 83
             $origin = $this->request->server['HTTP_ORIGIN'];
84 84
         } else {
85 85
             $origin = '*';
@@ -88,7 +88,7 @@  discard block
 block discarded – undo
88 88
         $response = new Response();
89 89
         $response->addHeader('Access-Control-Allow-Origin', $origin);
90 90
         $response->addHeader('Access-Control-Allow-Methods', $this->corsMethods);
91
-        $response->addHeader('Access-Control-Max-Age', (string)$this->corsMaxAge);
91
+        $response->addHeader('Access-Control-Max-Age', (string) $this->corsMaxAge);
92 92
         $response->addHeader('Access-Control-Allow-Headers', $this->corsAllowedHeaders);
93 93
         $response->addHeader('Access-Control-Allow-Credentials', 'false');
94 94
         return $response;
Please login to merge, or discard this patch.
lib/public/Files/IAppData.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,6 +30,6 @@
 block discarded – undo
30 30
  * @package OCP\Files
31 31
  * @since 11.0.0
32 32
  */
33
-interface IAppData extends ISimpleRoot  {
33
+interface IAppData extends ISimpleRoot {
34 34
 	
35 35
 }
Please login to merge, or discard this patch.
apps/files_external/lib/Command/Create.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -128,32 +128,32 @@  discard block
 block discarded – undo
128 128
 		$authBackend = $this->backendService->getAuthMechanism($authIdentifier);
129 129
 
130 130
 		if (!Filesystem::isValidPath($mountPoint)) {
131
-			$output->writeln('<error>Invalid mountpoint "' . $mountPoint . '"</error>');
131
+			$output->writeln('<error>Invalid mountpoint "'.$mountPoint.'"</error>');
132 132
 			return 1;
133 133
 		}
134 134
 		if (is_null($storageBackend)) {
135
-			$output->writeln('<error>Storage backend with identifier "' . $storageIdentifier . '" not found (see `occ files_external:backends` for possible values)</error>');
135
+			$output->writeln('<error>Storage backend with identifier "'.$storageIdentifier.'" not found (see `occ files_external:backends` for possible values)</error>');
136 136
 			return 404;
137 137
 		}
138 138
 		if (is_null($authBackend)) {
139
-			$output->writeln('<error>Authentication backend with identifier "' . $authIdentifier . '" not found (see `occ files_external:backends` for possible values)</error>');
139
+			$output->writeln('<error>Authentication backend with identifier "'.$authIdentifier.'" not found (see `occ files_external:backends` for possible values)</error>');
140 140
 			return 404;
141 141
 		}
142 142
 		$supportedSchemes = array_keys($storageBackend->getAuthSchemes());
143 143
 		if (!in_array($authBackend->getScheme(), $supportedSchemes)) {
144
-			$output->writeln('<error>Authentication backend "' . $authIdentifier . '" not valid for storage backend "' . $storageIdentifier . '" (see `occ files_external:backends storage ' . $storageIdentifier . '` for possible values)</error>');
144
+			$output->writeln('<error>Authentication backend "'.$authIdentifier.'" not valid for storage backend "'.$storageIdentifier.'" (see `occ files_external:backends storage '.$storageIdentifier.'` for possible values)</error>');
145 145
 			return 1;
146 146
 		}
147 147
 
148 148
 		$config = [];
149 149
 		foreach ($configInput as $configOption) {
150 150
 			if (!strpos($configOption, '=')) {
151
-				$output->writeln('<error>Invalid mount configuration option "' . $configOption . '"</error>');
151
+				$output->writeln('<error>Invalid mount configuration option "'.$configOption.'"</error>');
152 152
 				return 1;
153 153
 			}
154 154
 			list($key, $value) = explode('=', $configOption, 2);
155 155
 			if (!$this->validateParam($key, $value, $storageBackend, $authBackend)) {
156
-				$output->writeln('<error>Unknown configuration for backends "' . $key . '"</error>');
156
+				$output->writeln('<error>Unknown configuration for backends "'.$key.'"</error>');
157 157
 				return 1;
158 158
 			}
159 159
 			$config[$key] = $value;
@@ -167,7 +167,7 @@  discard block
 block discarded – undo
167 167
 
168 168
 		if ($user) {
169 169
 			if (!$this->userManager->userExists($user)) {
170
-				$output->writeln('<error>User "' . $user . '" not found</error>');
170
+				$output->writeln('<error>User "'.$user.'" not found</error>');
171 171
 				return 1;
172 172
 			}
173 173
 			$mount->setApplicableUsers([$user]);
@@ -178,9 +178,9 @@  discard block
 block discarded – undo
178 178
 		} else {
179 179
 			$this->getStorageService($user)->addStorage($mount);
180 180
 			if ($input->getOption('output') === self::OUTPUT_FORMAT_PLAIN) {
181
-				$output->writeln('<info>Storage created with id ' . $mount->getId() . '</info>');
181
+				$output->writeln('<info>Storage created with id '.$mount->getId().'</info>');
182 182
 			} else {
183
-				$output->writeln((string)$mount->getId());
183
+				$output->writeln((string) $mount->getId());
184 184
 			}
185 185
 		}
186 186
 		return 0;
Please login to merge, or discard this patch.
lib/private/Files/Storage/Home.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -50,7 +50,7 @@
 block discarded – undo
50 50
 	public function __construct($arguments) {
51 51
 		$this->user = $arguments['user'];
52 52
 		$datadir = $this->user->getHome();
53
-		$this->id = 'home::' . $this->user->getUID();
53
+		$this->id = 'home::'.$this->user->getUID();
54 54
 
55 55
 		parent::__construct(['datadir' => $datadir]);
56 56
 	}
Please login to merge, or discard this patch.
lib/private/DB/QueryBuilder/ExpressionBuilder/OCIExpressionBuilder.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
 	public function castColumn($column, $type) {
148 148
 		if ($type === IQueryBuilder::PARAM_STR) {
149 149
 			$column = $this->helper->quoteColumnName($column);
150
-			return new QueryFunction('to_char(' . $column . ')');
150
+			return new QueryFunction('to_char('.$column.')');
151 151
 		}
152 152
 
153 153
 		return parent::castColumn($column, $type);
@@ -157,7 +157,7 @@  discard block
 block discarded – undo
157 157
 	 * @inheritdoc
158 158
 	 */
159 159
 	public function like($x, $y, $type = null) {
160
-		return parent::like($x, $y, $type) . " ESCAPE '\\'";
160
+		return parent::like($x, $y, $type)." ESCAPE '\\'";
161 161
 	}
162 162
 
163 163
 	/**
@@ -166,6 +166,6 @@  discard block
 block discarded – undo
166 166
 	public function iLike($x, $y, $type = null) {
167 167
 		$x = $this->helper->quoteColumnName($x);
168 168
 		$y = $this->helper->quoteColumnName($y);
169
-		return new QueryFunction('REGEXP_LIKE(' . $x . ', \'^\' || REPLACE(REPLACE(' . $y . ', \'%\', \'.*\'), \'_\', \'.\') || \'$\', \'i\')');
169
+		return new QueryFunction('REGEXP_LIKE('.$x.', \'^\' || REPLACE(REPLACE('.$y.', \'%\', \'.*\'), \'_\', \'.\') || \'$\', \'i\')');
170 170
 	}
171 171
 }
Please login to merge, or discard this patch.
core/Command/Db/ConvertType.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -233,7 +233,7 @@  discard block
 block discarded – undo
233 233
 
234 234
 		$schemaManager = new \OC\DB\MDB2SchemaManager($toDB);
235 235
 		$apps = $input->getOption('all-apps') ? \OC_App::getAllApps() : \OC_App::getEnabledApps();
236
-		foreach($apps as $app) {
236
+		foreach ($apps as $app) {
237 237
 			if (file_exists(\OC_App::getAppPath($app).'/appinfo/database.xml')) {
238 238
 				$schemaManager->createDbFromStructure(\OC_App::getAppPath($app).'/appinfo/database.xml');
239 239
 			} else {
@@ -269,13 +269,13 @@  discard block
 block discarded – undo
269 269
 		if (!empty($toTables)) {
270 270
 			$output->writeln('<info>Clearing schema in new database</info>');
271 271
 		}
272
-		foreach($toTables as $table) {
272
+		foreach ($toTables as $table) {
273 273
 			$db->getSchemaManager()->dropTable($table);
274 274
 		}
275 275
 	}
276 276
 
277 277
 	protected function getTables(Connection $db) {
278
-		$filterExpression = '/^' . preg_quote($this->config->getSystemValue('dbtableprefix', 'oc_')) . '/';
278
+		$filterExpression = '/^'.preg_quote($this->config->getSystemValue('dbtableprefix', 'oc_')).'/';
279 279
 		$db->getConfiguration()->
280 280
 			setFilterSchemaAssetsExpression($filterExpression);
281 281
 		return $db->getSchemaManager()->listTableNames();
@@ -290,7 +290,7 @@  discard block
 block discarded – undo
290 290
 	 * @suppress SqlInjectionChecker
291 291
 	 */
292 292
 	protected function copyTable(Connection $fromDB, Connection $toDB, Table $table, InputInterface $input, OutputInterface $output) {
293
-		if ($table->getName() === $toDB->getPrefix() . 'migrations') {
293
+		if ($table->getName() === $toDB->getPrefix().'migrations') {
294 294
 			$output->writeln('<comment>Skipping migrations table because it was already filled by running the migrations</comment>');
295 295
 			return;
296 296
 		}
@@ -305,9 +305,9 @@  discard block
 block discarded – undo
305 305
 		$count = $result->fetchColumn();
306 306
 		$result->closeCursor();
307 307
 
308
-		$numChunks = ceil($count/$chunkSize);
308
+		$numChunks = ceil($count / $chunkSize);
309 309
 		if ($numChunks > 1) {
310
-			$output->writeln('chunked query, ' . $numChunks . ' chunks');
310
+			$output->writeln('chunked query, '.$numChunks.' chunks');
311 311
 		}
312 312
 
313 313
 		$progress = new ProgressBar($output, $count);
@@ -394,7 +394,7 @@  discard block
 block discarded – undo
394 394
 
395 395
 		try {
396 396
 			// copy table rows
397
-			foreach($tables as $table) {
397
+			foreach ($tables as $table) {
398 398
 				$output->writeln($table);
399 399
 				$this->copyTable($fromDB, $toDB, $schema->getTable($table), $input, $output);
400 400
 			}
@@ -404,7 +404,7 @@  discard block
 block discarded – undo
404 404
 			}
405 405
 			// save new database config
406 406
 			$this->saveDBInfo($input);
407
-		} catch(\Exception $e) {
407
+		} catch (\Exception $e) {
408 408
 			$this->config->setSystemValue('maintenance', false);
409 409
 			throw $e;
410 410
 		}
Please login to merge, or discard this patch.
lib/private/L10N/L10NString.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -56,19 +56,19 @@
 block discarded – undo
56 56
 		$translations = $this->l10n->getTranslations();
57 57
 
58 58
 		$text = $this->text;
59
-		if(array_key_exists($this->text, $translations)) {
60
-			if(is_array($translations[$this->text])) {
59
+		if (array_key_exists($this->text, $translations)) {
60
+			if (is_array($translations[$this->text])) {
61 61
 				$fn = $this->l10n->getPluralFormFunction();
62 62
 				$id = $fn($this->count);
63 63
 				$text = $translations[$this->text][$id];
64 64
 			}
65
-			else{
65
+			else {
66 66
 				$text = $translations[$this->text];
67 67
 			}
68 68
 		}
69 69
 
70 70
 		// Replace %n first (won't interfere with vsprintf)
71
-		$text = str_replace('%n', (string)$this->count, $text);
71
+		$text = str_replace('%n', (string) $this->count, $text);
72 72
 		return vsprintf($text, $this->parameters);
73 73
 	}
74 74
 
Please login to merge, or discard this patch.
lib/private/App/AppStore/Bundles/EducationBundle.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
 	 * {@inheritDoc}
28 28
 	 */
29 29
 	public function getName() {
30
-		return (string)$this->l10n->t('Education Edition');
30
+		return (string) $this->l10n->t('Education Edition');
31 31
 	}
32 32
 
33 33
 	/**
Please login to merge, or discard this patch.