diff --git a/Classes/Middleware/Embedded3dViewer.php b/Classes/Middleware/Embedded3dViewer.php index 8b0cb9a2c..a79591884 100644 --- a/Classes/Middleware/Embedded3dViewer.php +++ b/Classes/Middleware/Embedded3dViewer.php @@ -16,11 +16,13 @@ use Psr\Http\Message\ServerRequestInterface; use Psr\Http\Server\MiddlewareInterface; use Psr\Http\Server\RequestHandlerInterface; +use Psr\Log\LoggerAwareInterface; use Psr\Log\LoggerAwareTrait; use TYPO3\CMS\Core\Configuration\ExtensionConfiguration; use TYPO3\CMS\Core\Configuration\Loader\YamlFileLoader; use TYPO3\CMS\Core\Exception; use TYPO3\CMS\Core\Http\HtmlResponse; +use TYPO3\CMS\Core\Log\LogManager; use TYPO3\CMS\Core\Resource\Folder; use TYPO3\CMS\Core\Resource\ResourceFactory; use TYPO3\CMS\Core\Resource\StorageRepository; @@ -35,7 +37,7 @@ * @subpackage dlf * @access public */ -class Embedded3dViewer implements MiddlewareInterface +class Embedded3dViewer implements LoggerAwareInterface, MiddlewareInterface { use LoggerAwareTrait; @@ -63,6 +65,8 @@ public function process(ServerRequestInterface $request, RequestHandlerInterface return $response; } + $this->logger = GeneralUtility::makeInstance(LogManager::class)->getLogger(__CLASS__); + if (empty($parameters['model'])) { return $this->warningResponse('Model url is missing.', $request); }