diff --git a/netlib/encoding.py b/netlib/encoding.py index 040aceaf9..d25af3e5d 100644 --- a/netlib/encoding.py +++ b/netlib/encoding.py @@ -76,7 +76,7 @@ def encode(decoded, encoding, errors='strict'): Raises: ValueError, if encoding fails. """ - if len(decoded) == 0: + if len(decoded) == 0 or encoding == "none": return decoded global _cache