From 39acf1dbd250df61ebfa7871384cd73cb6669c6d Mon Sep 17 00:00:00 2001 From: Alex Gaynor Date: Sun, 31 Mar 2013 23:20:46 -0700 Subject: [PATCH] is should not be used for comparing numbers --- requests/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requests/models.py b/requests/models.py index 6ed2b59..2850950 100644 --- a/requests/models.py +++ b/requests/models.py @@ -575,7 +575,7 @@ class Response(object): raise RuntimeError( 'The content for this response was already consumed') - if self.status_code is 0: + if self.status_code == 0: self._content = None else: self._content = bytes().join(self.iter_content(CONTENT_CHUNK_SIZE)) or bytes() -- 2.34.1