Commit 0796d9e4 authored by Matthias Adrowski's avatar Matthias Adrowski
Browse files

[TASK] Update Middleware Stack

parent 0cbc5b58
......@@ -24,6 +24,29 @@
* This copyright notice MUST APPEAR in all copies of the script!
*/
if (version_compare(\TYPO3\CMS\Core\Utility\VersionNumberUtility::getCurrentTypo3Version(), '11.0.0', '<')) {
return [
'frontend' => [
// register the REST dispatcher middleware
'sgalinski/sg-rest/dispatcher' => [
'target' => \SGalinski\SgRest\Middleware\RestDispatcher::class,
'description' => 'Dispatches a REST request',
'before' => [
'typo3/cms-frontend/site-resolver'
]
],
// register the REST authenticator middleware
'sgalinski/sg-rest/authenticator' => [
'target' => \SGalinski\SgRest\Middleware\RestAuthenticator::class,
'description' => 'Authenticates a REST request',
'before' => [
'sgalinski/sg-rest/dispatcher'
]
]
]
];
}
return [
'frontend' => [
// register the REST dispatcher middleware
......@@ -31,7 +54,7 @@ return [
'target' => \SGalinski\SgRest\Middleware\RestDispatcher::class,
'description' => 'Dispatches a REST request',
'before' => [
'typo3/cms-frontend/site-resolver'
'typo3/cms-frontend/site'
]
],
// register the REST authenticator middleware
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment