summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristoph Wurst <christoph@winzerhof-wurst.at>2020-04-10 16:56:50 +0200
committerChristoph Wurst <christoph@winzerhof-wurst.at>2020-04-10 16:56:50 +0200
commit734c62bee0f46652285f782761317889d1ef5c7d (patch)
treef9fe648d23372244f1d687d49b6c66126469d3f4
parent28f8eb5dba60a75f7e22debbdc26f1d3164deb18 (diff)
downloadnextcloud-server-734c62bee0f46652285f782761317889d1ef5c7d.tar.gz
nextcloud-server-734c62bee0f46652285f782761317889d1ef5c7d.zip
Format code according to PSR2
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
-rw-r--r--apps/dav/lib/Connector/Sabre/Directory.php3
-rw-r--r--apps/dav/lib/Files/FileSearchBackend.php1
-rw-r--r--apps/dav/tests/unit/CardDAV/ConverterTest.php2
-rw-r--r--apps/encryption/lib/Settings/Personal.php2
-rw-r--r--apps/files_trashbin/lib/Sabre/AbstractTrashFile.php2
-rw-r--r--apps/user_ldap/lib/Connection.php1
-rw-r--r--core/Command/Config/System/SetConfig.php1
-rw-r--r--lib/private/AppFramework/Http/Request.php2
-rw-r--r--lib/private/Files/Cache/QuerySearchHelper.php1
-rw-r--r--lib/private/Files/ObjectStore/ObjectStoreStorage.php1
-rw-r--r--lib/private/Files/Storage/Flysystem.php1
-rw-r--r--lib/private/Group/Database.php4
-rw-r--r--lib/private/L10N/LanguageIterator.php5
-rw-r--r--lib/private/MemoryInfo.php2
-rw-r--r--lib/private/User/Database.php4
15 files changed, 22 insertions, 10 deletions
diff --git a/apps/dav/lib/Connector/Sabre/Directory.php b/apps/dav/lib/Connector/Sabre/Directory.php
index 0e4ddd1f232..a7c319b4eee 100644
--- a/apps/dav/lib/Connector/Sabre/Directory.php
+++ b/apps/dav/lib/Connector/Sabre/Directory.php
@@ -50,8 +50,7 @@ use Sabre\DAV\Exception\ServiceUnavailable;
use Sabre\DAV\IFile;
use Sabre\DAV\INode;
-class Directory extends \OCA\DAV\Connector\Sabre\Node
- implements \Sabre\DAV\ICollection, \Sabre\DAV\IQuota, \Sabre\DAV\IMoveTarget {
+class Directory extends \OCA\DAV\Connector\Sabre\Node implements \Sabre\DAV\ICollection, \Sabre\DAV\IQuota, \Sabre\DAV\IMoveTarget {
/**
* Cached directory content
diff --git a/apps/dav/lib/Files/FileSearchBackend.php b/apps/dav/lib/Files/FileSearchBackend.php
index fd951961623..a69236ffd51 100644
--- a/apps/dav/lib/Files/FileSearchBackend.php
+++ b/apps/dav/lib/Files/FileSearchBackend.php
@@ -428,6 +428,7 @@ class FileSearchBackend implements ISearchBackend {
} else {
return null;
}
+ // no break
default:
return null;
}
diff --git a/apps/dav/tests/unit/CardDAV/ConverterTest.php b/apps/dav/tests/unit/CardDAV/ConverterTest.php
index da2255a7172..d502783ba41 100644
--- a/apps/dav/tests/unit/CardDAV/ConverterTest.php
+++ b/apps/dav/tests/unit/CardDAV/ConverterTest.php
@@ -34,7 +34,7 @@ use OCP\IUser;
use PHPUnit_Framework_MockObject_MockObject;
use Test\TestCase;
-class ConverterTest extends TestCase {
+class ConverterTest extends TestCase {
/** @var AccountManager | PHPUnit_Framework_MockObject_MockObject */
private $accountManager;
diff --git a/apps/encryption/lib/Settings/Personal.php b/apps/encryption/lib/Settings/Personal.php
index 7ecf457e641..bd0e17f0282 100644
--- a/apps/encryption/lib/Settings/Personal.php
+++ b/apps/encryption/lib/Settings/Personal.php
@@ -30,7 +30,7 @@ use OCP\IConfig;
use OCP\IUserSession;
use OCP\Settings\ISettings;
-class Personal implements ISettings {
+class Personal implements ISettings {
/** @var IConfig */
private $config;
diff --git a/apps/files_trashbin/lib/Sabre/AbstractTrashFile.php b/apps/files_trashbin/lib/Sabre/AbstractTrashFile.php
index ad80711ff1d..7f606bbbc6e 100644
--- a/apps/files_trashbin/lib/Sabre/AbstractTrashFile.php
+++ b/apps/files_trashbin/lib/Sabre/AbstractTrashFile.php
@@ -29,7 +29,7 @@ namespace OCA\Files_Trashbin\Sabre;
use Sabre\DAV\Exception\Forbidden;
use Sabre\DAV\IFile;
-abstract class AbstractTrashFile extends AbstractTrash implements IFile , ITrash {
+abstract class AbstractTrashFile extends AbstractTrash implements IFile, ITrash {
public function put($data) {
throw new Forbidden();
}
diff --git a/apps/user_ldap/lib/Connection.php b/apps/user_ldap/lib/Connection.php
index cec4866b0ea..0cc93a08e6f 100644
--- a/apps/user_ldap/lib/Connection.php
+++ b/apps/user_ldap/lib/Connection.php
@@ -348,6 +348,7 @@ class Connection extends LDAPUtility {
$result[$dbkey] = implode("\n", $config[$configkey]);
break;
} //else follows default
+ // no break
default:
$result[$dbkey] = $config[$configkey];
}
diff --git a/core/Command/Config/System/SetConfig.php b/core/Command/Config/System/SetConfig.php
index 0f0d28a038d..53f007a97e2 100644
--- a/core/Command/Config/System/SetConfig.php
+++ b/core/Command/Config/System/SetConfig.php
@@ -150,6 +150,7 @@ class SetConfig extends Base {
throw new \InvalidArgumentException('Unable to parse value as boolean');
}
+ // no break
case 'null':
return [
'value' => null,
diff --git a/lib/private/AppFramework/Http/Request.php b/lib/private/AppFramework/Http/Request.php
index c9b22dd7a1e..2ef7b4a0995 100644
--- a/lib/private/AppFramework/Http/Request.php
+++ b/lib/private/AppFramework/Http/Request.php
@@ -282,7 +282,7 @@ class Request implements \ArrayAccess, \Countable, IRequest {
case 'parameters':
case 'params':
return $this->getContent();
- default;
+ default:
return isset($this[$name])
? $this[$name]
: null;
diff --git a/lib/private/Files/Cache/QuerySearchHelper.php b/lib/private/Files/Cache/QuerySearchHelper.php
index eba4178d9bd..e1ecad50733 100644
--- a/lib/private/Files/Cache/QuerySearchHelper.php
+++ b/lib/private/Files/Cache/QuerySearchHelper.php
@@ -110,6 +110,7 @@ class QuerySearchHelper {
} else {
throw new \InvalidArgumentException('Binary operators inside "not" is not supported');
}
+ // no break
case ISearchBinaryOperator::OPERATOR_AND:
return call_user_func_array([$expr, 'andX'], $this->searchOperatorArrayToDBExprArray($builder, $operator->getArguments()));
case ISearchBinaryOperator::OPERATOR_OR:
diff --git a/lib/private/Files/ObjectStore/ObjectStoreStorage.php b/lib/private/Files/ObjectStore/ObjectStoreStorage.php
index 1faa44ad888..a5112bcbba6 100644
--- a/lib/private/Files/ObjectStore/ObjectStoreStorage.php
+++ b/lib/private/Files/ObjectStore/ObjectStoreStorage.php
@@ -304,6 +304,7 @@ class ObjectStoreStorage extends \OC\Files\Storage\Common {
} else {
return false;
}
+ // no break
case 'w':
case 'wb':
case 'w+':
diff --git a/lib/private/Files/Storage/Flysystem.php b/lib/private/Files/Storage/Flysystem.php
index 2644bfbb1d3..fba64c64250 100644
--- a/lib/private/Files/Storage/Flysystem.php
+++ b/lib/private/Files/Storage/Flysystem.php
@@ -189,6 +189,7 @@ abstract class Flysystem extends Common {
case 'wb':
case 'wb+':
$useExisting = false;
+ // no break
case 'a':
case 'ab':
case 'r+':
diff --git a/lib/private/Group/Database.php b/lib/private/Group/Database.php
index b75dc097c97..1202ba09b13 100644
--- a/lib/private/Group/Database.php
+++ b/lib/private/Group/Database.php
@@ -60,8 +60,8 @@ use OCP\IDBConnection;
/**
* Class for group management in a SQL Database (e.g. MySQL, SQLite)
*/
-class Database extends ABackend
- implements IAddToGroupBackend,
+class Database extends ABackend implements
+ IAddToGroupBackend,
ICountDisabledInGroup,
ICountUsersBackend,
ICreateGroupBackend,
diff --git a/lib/private/L10N/LanguageIterator.php b/lib/private/L10N/LanguageIterator.php
index 0670ac56503..a03ec114ef9 100644
--- a/lib/private/L10N/LanguageIterator.php
+++ b/lib/private/L10N/LanguageIterator.php
@@ -64,6 +64,7 @@ class LanguageIterator implements ILanguageIterator {
}
$this->next();
/** @noinspection PhpMissingBreakStatementInspection */
+ // no break
case 1:
$forcedLang = $this->config->getSystemValue('force_language', false);
if (is_string($forcedLang)
@@ -73,6 +74,7 @@ class LanguageIterator implements ILanguageIterator {
}
$this->next();
/** @noinspection PhpMissingBreakStatementInspection */
+ // no break
case 2:
$userLang = $this->config->getUserValue($this->user->getUID(), 'core', 'lang', null);
if (is_string($userLang)) {
@@ -80,6 +82,7 @@ class LanguageIterator implements ILanguageIterator {
}
$this->next();
/** @noinspection PhpMissingBreakStatementInspection */
+ // no break
case 3:
$userLang = $this->config->getUserValue($this->user->getUID(), 'core', 'lang', null);
if (is_string($userLang)
@@ -88,6 +91,7 @@ class LanguageIterator implements ILanguageIterator {
return $truncated;
}
$this->next();
+ // no break
case 4:
return $this->config->getSystemValue('default_language', 'en');
/** @noinspection PhpMissingBreakStatementInspection */
@@ -97,6 +101,7 @@ class LanguageIterator implements ILanguageIterator {
return $truncated;
}
$this->next();
+ // no break
default:
return 'en';
}
diff --git a/lib/private/MemoryInfo.php b/lib/private/MemoryInfo.php
index 0e70b500532..88ba69aae95 100644
--- a/lib/private/MemoryInfo.php
+++ b/lib/private/MemoryInfo.php
@@ -72,8 +72,10 @@ class MemoryInfo {
switch ($last) {
case 'g':
$memoryLimit *= 1024;
+ // no break
case 'm':
$memoryLimit *= 1024;
+ // no break
case 'k':
$memoryLimit *= 1024;
}
diff --git a/lib/private/User/Database.php b/lib/private/User/Database.php
index d5098483d61..e88549c8d81 100644
--- a/lib/private/User/Database.php
+++ b/lib/private/User/Database.php
@@ -76,8 +76,8 @@ use OCP\User\Backend\ISetPasswordBackend;
/**
* Class for user management in a SQL Database (e.g. MySQL, SQLite)
*/
-class Database extends ABackend
- implements ICreateUserBackend,
+class Database extends ABackend implements
+ ICreateUserBackend,
ISetPasswordBackend,
ISetDisplayNameBackend,
IGetDisplayNameBackend,