aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2023-09-09 09:51:17 +0200
committerGitHub <noreply@github.com>2023-09-09 09:51:17 +0200
commit938a5580786a1bd5d486d4f7521c781b737f5119 (patch)
treefca1f469d68acc8b6beeb9a467ac3c45913f6d71 /tests
parentc18962252921f7e70a48ad1d734a168e6f7e3d08 (diff)
parent271e63e41c26b77bdff8b15c04163195dc7b7a55 (diff)
downloadnextcloud-server-938a5580786a1bd5d486d4f7521c781b737f5119.tar.gz
nextcloud-server-938a5580786a1bd5d486d4f7521c781b737f5119.zip
Merge pull request #39226 from shdehnavi/null_coalescing_conversion_tests
Diffstat (limited to 'tests')
-rw-r--r--tests/lib/Util/User/Dummy.php2
-rw-r--r--tests/lib/UtilCheckServerTest.php2
2 files changed, 2 insertions, 2 deletions
diff --git a/tests/lib/Util/User/Dummy.php b/tests/lib/Util/User/Dummy.php
index 478b7599701..7106d879256 100644
--- a/tests/lib/Util/User/Dummy.php
+++ b/tests/lib/Util/User/Dummy.php
@@ -168,7 +168,7 @@ class Dummy extends Backend implements \OCP\IUserBackend {
}
public function getDisplayName($uid) {
- return isset($this->displayNames[$uid])? $this->displayNames[$uid]: $uid;
+ return $this->displayNames[$uid] ?? $uid;
}
/**
diff --git a/tests/lib/UtilCheckServerTest.php b/tests/lib/UtilCheckServerTest.php
index 9ddb1f8e45f..7e47734ede7 100644
--- a/tests/lib/UtilCheckServerTest.php
+++ b/tests/lib/UtilCheckServerTest.php
@@ -30,7 +30,7 @@ class UtilCheckServerTest extends \Test\TestCase {
$config->expects($this->any())
->method('getValue')
->willReturnCallback(function ($key, $default) use ($systemOptions) {
- return isset($systemOptions[$key]) ? $systemOptions[$key] : $default;
+ return $systemOptions[$key] ?? $default;
});
return $config;
}