Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error if we use empty() response #10

Open
ZeJ0hn opened this issue Jul 6, 2021 · 0 comments
Open

Error if we use empty() response #10

ZeJ0hn opened this issue Jul 6, 2021 · 0 comments

Comments

@ZeJ0hn
Copy link

ZeJ0hn commented Jul 6, 2021

If we use empty() as Sanic response, the content_type is None and the middleware returns an error:

  File "/usr/local/lib/python3.8/site-packages/sanic_compress/__init__.py", line 34, in _compress_response
    if ';' in response.content_type:
TypeError: argument of type 'NoneType' is not iterable"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant