summaryrefslogtreecommitdiffstats
path: root/lib/private/URLGenerator.php
diff options
context:
space:
mode:
authorJonas Meurer <jonas@freesources.org>2021-08-10 11:06:24 +0200
committerJonas Meurer <jonas@freesources.org>2021-08-16 10:56:47 +0200
commit7c76e85ddefc481fd9582560c59c4883dbd7caad (patch)
tree7c5012d53d88a725cff1b2fafebf91d2779586d0 /lib/private/URLGenerator.php
parent5f5bacde8f6f65eeaba0d1b86eb134b5527c0d54 (diff)
downloadnextcloud-server-7c76e85ddefc481fd9582560c59c4883dbd7caad.tar.gz
nextcloud-server-7c76e85ddefc481fd9582560c59c4883dbd7caad.zip
Use IURLGenerator function to get value of `\OC::$WEBROOT` global
Signed-off-by: Jonas Meurer <jonas@freesources.org>
Diffstat (limited to 'lib/private/URLGenerator.php')
-rw-r--r--lib/private/URLGenerator.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/private/URLGenerator.php b/lib/private/URLGenerator.php
index 34bb65cd0e6..f7fa6fa5632 100644
--- a/lib/private/URLGenerator.php
+++ b/lib/private/URLGenerator.php
@@ -276,4 +276,11 @@ class URLGenerator implements IURLGenerator {
}
return $this->baseUrl;
}
+
+ /**
+ * @return string webroot part of the base url
+ */
+ public function getWebroot(): string {
+ return \OC::$WEBROOT;
+ }
}