component AP gateway: fix header checking for redirection

This commit is contained in:
Goffi 2022-11-25 16:14:10 +01:00
commit 9560a23f78

View file

@ -942,7 +942,7 @@ class HTTPAPGServer(web_resource.Resource):
path
)
request_type, extra_args = self.apg.parseAPURL(ap_url)
if ((request.getHeader("accept") != MEDIA_TYPE_AP
if ((MEDIA_TYPE_AP in (request.getHeader("accept") or "")
and request_type in self.apg.html_redirect)):
# this is not a AP request, and we have a redirections for it
kw = {}