fix(status): route status exempt from approot normalisation, might not fix the issue yet

This commit is contained in:
Steffen Jost 2021-12-08 16:34:55 +01:00
parent 1c5dc74edf
commit 074a33dc51

View File

@ -137,6 +137,7 @@ yesodMiddleware = cacheControlMiddleware . storeBearerMiddleware . csrfMiddlewar
case route of
MetricsR -> mzero
HealthR -> mzero
StatusR -> mzero
InstanceR -> mzero
AdminCrontabR -> mzero
_other -> return ()
@ -147,7 +148,7 @@ yesodMiddleware = cacheControlMiddleware . storeBearerMiddleware . csrfMiddlewar
approotHost <- hoistMaybe $ approotScopeHost rApproot app
let doRedirect = do
url <- approotRender rApproot route
$logDebugS "normalizeApprootMiddleware" url
$logDebugS "normalizeApprootMiddleware redirect" url
redirect url
if | approotHost /= reqHost
, rApproot /= ApprootUserGenerated