From 5ccfd8f099b16eea2cf8e1b590fd899f607a329a Mon Sep 17 00:00:00 2001 From: Dave MacFarlane Date: Tue, 25 Oct 2022 14:38:35 -0400 Subject: [PATCH] Missed a code path --- src/Router/BaseRouter.php | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/Router/BaseRouter.php b/src/Router/BaseRouter.php index e598c3009aa..5eb504b7c12 100644 --- a/src/Router/BaseRouter.php +++ b/src/Router/BaseRouter.php @@ -144,7 +144,17 @@ public function handle(ServerRequestInterface $request) : ResponseInterface ->withAttribute("baseurl", $baseurl->__toString()) ->withAttribute("CandID", $components[0]); $module = \Module::factory("timepoint_list"); - $mr = new ModuleRouter($module); + + $requestloglevel = $logSettings->getRequestLogLevel(); + if ($requestloglevel != "none") { + $module->setLogger( + new \LORIS\Log\ErrorLogLogger($requestloglevel) + ); + } else { + $module->setLogger(new \PSR\Log\NullLogger); + } + + $mr = new ModuleRouter($module); return $ehandler->process($request, $mr); } }