diff options
-rw-r--r-- | lib/private/route/router.php | 6 |
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 ''; |