aboutsummaryrefslogtreecommitdiffstats
path: root/public.php
diff options
context:
space:
mode:
authorJohn Molakvoæ <skjnldsv@protonmail.com>2023-12-29 10:16:08 +0100
committerJohn Molakvoæ <skjnldsv@protonmail.com>2024-01-09 11:08:46 +0100
commit9e4c9b97ddf96b1a9379f5bdc5ecd1c24021291c (patch)
treea26e1bb0650fc4701aab4f1a444ea3ca8322695d /public.php
parent18399fc1cf01bdabfeecba1fbf3923dc30db4229 (diff)
downloadnextcloud-server-9e4c9b97ddf96b1a9379f5bdc5ecd1c24021291c.tar.gz
nextcloud-server-9e4c9b97ddf96b1a9379f5bdc5ecd1c24021291c.zip
fix(psalm): update baseline and suppress unnecessary issues
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
Diffstat (limited to 'public.php')
-rw-r--r--public.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/public.php b/public.php
index 5954da7e3a0..9f3ffcec5e9 100644
--- a/public.php
+++ b/public.php
@@ -36,7 +36,7 @@ require_once __DIR__ . '/lib/versioncheck.php';
* @param $service
* @return string
*/
-function resolveService($service) {
+function resolveService(string $service): string {
$services = [
'webdav' => 'dav/appinfo/v1/publicwebdav.php',
'dav' => 'dav/appinfo/v2/publicremote.php',
@@ -74,7 +74,7 @@ try {
$file = resolveService($service);
- if (is_null($file)) {
+ if (!$file) {
throw new RemoteException('Path not found', 404);
}