aboutsummaryrefslogtreecommitdiffstats
path: root/apps/encryption
diff options
context:
space:
mode:
authorCôme Chilliet <come.chilliet@nextcloud.com>2024-09-20 17:38:36 +0200
committerCôme Chilliet <come.chilliet@nextcloud.com>2024-09-20 17:51:00 +0200
commit1a4978c4ead55daa2726df5967c1377d61a57f7a (patch)
tree88c8a82ed52b8698be9e0cd4e9cef29b3c0d8ea1 /apps/encryption
parent6db9cbfdeb7dd475a258c1c2f2c163c41856d6c2 (diff)
downloadnextcloud-server-1a4978c4ead55daa2726df5967c1377d61a57f7a.tar.gz
nextcloud-server-1a4978c4ead55daa2726df5967c1377d61a57f7a.zip
chore: Apply rector configuration to apps folder
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Diffstat (limited to 'apps/encryption')
-rw-r--r--apps/encryption/lib/AppInfo/Application.php2
-rw-r--r--apps/encryption/tests/Crypto/EncryptionTest.php4
-rw-r--r--apps/encryption/tests/Hooks/UserHooksTest.php2
3 files changed, 4 insertions, 4 deletions
diff --git a/apps/encryption/lib/AppInfo/Application.php b/apps/encryption/lib/AppInfo/Application.php
index d3f7eb44145..d683c82286a 100644
--- a/apps/encryption/lib/AppInfo/Application.php
+++ b/apps/encryption/lib/AppInfo/Application.php
@@ -39,7 +39,7 @@ class Application extends App implements IBootstrap {
public function boot(IBootContext $context): void {
\OCP\Util::addScript(self::APP_ID, 'encryption');
- $context->injectFn(function (IManager $encryptionManager) use ($context) {
+ $context->injectFn(function (IManager $encryptionManager) use ($context): void {
if (!($encryptionManager instanceof \OC\Encryption\Manager)) {
return;
}
diff --git a/apps/encryption/tests/Crypto/EncryptionTest.php b/apps/encryption/tests/Crypto/EncryptionTest.php
index 10f85f7e74e..70c9899cf81 100644
--- a/apps/encryption/tests/Crypto/EncryptionTest.php
+++ b/apps/encryption/tests/Crypto/EncryptionTest.php
@@ -317,7 +317,7 @@ class EncryptionTest extends TestCase {
$this->keyManagerMock->expects($this->never())->method('getPublicKey');
$this->keyManagerMock->expects($this->never())->method('addSystemKeys');
$this->keyManagerMock->expects($this->once())->method('setVersion')
- ->willReturnCallback(function ($path, $version, $view) {
+ ->willReturnCallback(function ($path, $version, $view): void {
$this->assertSame('path', $path);
$this->assertSame(2, $version);
$this->assertTrue($view instanceof \OC\Files\View);
@@ -335,7 +335,7 @@ class EncryptionTest extends TestCase {
$this->keyManagerMock->expects($this->any())
->method('getPublicKey')->willReturnCallback(
- function ($user) {
+ function ($user): void {
throw new PublicKeyMissingException($user);
}
);
diff --git a/apps/encryption/tests/Hooks/UserHooksTest.php b/apps/encryption/tests/Hooks/UserHooksTest.php
index 3bb0b559fdf..f59a2fd8d01 100644
--- a/apps/encryption/tests/Hooks/UserHooksTest.php
+++ b/apps/encryption/tests/Hooks/UserHooksTest.php
@@ -204,7 +204,7 @@ class UserHooksTest extends TestCase {
$this->keyManagerMock->expects($this->exactly(4))
->method('setPrivateKey')
- ->willReturnCallback(function ($user, $key) {
+ ->willReturnCallback(function ($user, $key): void {
$header = substr($key, 0, strlen(Crypt::HEADER_START));
$this->assertSame(
Crypt::HEADER_START,