diff --git a/restapi/index.php b/restapi/index.php index 5bc4535eb..6f68aaac4 100644 --- a/restapi/index.php +++ b/restapi/index.php @@ -3281,7 +3281,7 @@ $container->set('notifier', $notifier); $container->set('authenticator', $authenticator); $container->set('translator', $translator); -$app->setBasePath($settings->_httpRoot."restapi/index.php"); +$app->setBasePath(rtrim($settings->_httpRoot, '/')."/restapi/index.php"); $app->add(new RestapiAuthMiddleware($container, $app->getResponseFactory())); diff --git a/www/index.php b/www/index.php index dd061117d..06f609252 100644 --- a/www/index.php +++ b/www/index.php @@ -61,6 +61,8 @@ if (true) { $container->set('authenticator', $authenticator); $container->set('translator', $translator); + $app->setBasePath(rtrim($settings->_httpRoot, '/')); + if (isset($GLOBALS['SEEDDMS_HOOKS']['initDMS'])) { foreach ($GLOBALS['SEEDDMS_HOOKS']['initDMS'] as $hookObj) { if (method_exists($hookObj, 'addMiddleware')) {