summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2016-01-04 15:00:06 +0100
committerThomas Müller <thomas.mueller@tmit.eu>2016-01-04 15:00:06 +0100
commit70ff90b1ec599a702a926f84baf18e744cc7529c (patch)
treee8eb2c939b2e3982cfc2104c499b9d48f5085e6f
parentebc52300e752c68b3f6dcc822894ad1ab85f0999 (diff)
parent9e39e8f1c77d39f977702a5240e67e2c57049ed7 (diff)
downloadnextcloud-server-70ff90b1ec599a702a926f84baf18e744cc7529c.tar.gz
nextcloud-server-70ff90b1ec599a702a926f84baf18e744cc7529c.zip
Merge pull request #21393 from owncloud/fix-urlgenerator-call
No more deprecation messages in error log
-rw-r--r--lib/private/route/router.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/private/route/router.php b/lib/private/route/router.php
index f144c543989..8d31d448855 100644
--- a/lib/private/route/router.php
+++ b/lib/private/route/router.php
@@ -328,7 +328,11 @@ class Router implements IRouter {
public function generate($name, $parameters = array(), $absolute = false) {
$this->loadRoutes();
try {
- return $this->getGenerator()->generate($name, $parameters, $absolute);
+ $referenceType = UrlGenerator::ABSOLUTE_URL;
+ if ($absolute === false) {
+ $referenceType = UrlGenerator::ABSOLUTE_PATH;
+ }
+ return $this->getGenerator()->generate($name, $parameters, $referenceType);
} catch (RouteNotFoundException $e) {
$this->logger->logException($e);
return '';