mirror of
https://github.com/home-assistant/core.git
synced 2025-07-22 12:47:08 +00:00
Enable compression for manifest.json (#110229)
Now that compression is ~5x faster than base zlib, it makes sense to compress this
This commit is contained in:
parent
a5cc0ae890
commit
2f7d71347e
@ -644,9 +644,11 @@ class ManifestJSONView(HomeAssistantView):
|
|||||||
@callback
|
@callback
|
||||||
def get(self, request: web.Request) -> web.Response:
|
def get(self, request: web.Request) -> web.Response:
|
||||||
"""Return the manifest.json."""
|
"""Return the manifest.json."""
|
||||||
return web.Response(
|
response = web.Response(
|
||||||
text=MANIFEST_JSON.json, content_type="application/manifest+json"
|
text=MANIFEST_JSON.json, content_type="application/manifest+json"
|
||||||
)
|
)
|
||||||
|
response.enable_compression()
|
||||||
|
return response
|
||||||
|
|
||||||
|
|
||||||
@websocket_api.websocket_command(
|
@websocket_api.websocket_command(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user