From 3321b467474645ec62723ada01b1df1058674488 Mon Sep 17 00:00:00 2001 From: Rodja Trappe Date: Fri, 22 Sep 2023 05:28:58 +0200 Subject: [PATCH] air: fixed header export as true list of tuples --- nicegui/air.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nicegui/air.py b/nicegui/air.py index 01da067ad..ed39d442e 100644 --- a/nicegui/air.py +++ b/nicegui/air.py @@ -47,7 +47,7 @@ async def on_http(data: Dict[str, Any]) -> Dict[str, Any]: response.headers.update({'content-encoding': 'gzip', 'content-length': str(len(compressed))}) return { 'status_code': response.status_code, - 'headers': list(response.headers.items()), # NOTE items() concatenates values for duplicate keys + 'headers': [(k.decode(), v.decode()) for k, v in headers.raw], 'content': compressed, }