]> source.dussan.org Git - nextcloud-server.git/commitdiff
filter index.php from cloudId 33780/head
authorMaxence Lange <maxence@artificial-owl.com>
Wed, 31 Aug 2022 19:33:09 +0000 (18:33 -0100)
committerMaxence Lange <maxence@artificial-owl.com>
Wed, 31 Aug 2022 19:33:09 +0000 (18:33 -0100)
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
lib/private/User/User.php

index 7f7d6273e306b7c0e2baa1ee90232e3b95323f61..78d4a51cf168138c3840fe76e65440550573a153 100644 (file)
@@ -556,6 +556,9 @@ class User implements IUser {
        public function getCloudId() {
                $uid = $this->getUID();
                $server = $this->urlGenerator->getAbsoluteURL('/');
+               if (substr($server, -10) === '/index.php') {
+                       $server = substr($server, 0, -10);
+               }
                $server = rtrim($this->removeProtocolFromUrl($server), '/');
                return $uid . '@' . $server;
        }