Check oauth_client is not None in AsyncBaseStream._connect
authorHarmon <Harmon758@gmail.com>
Wed, 5 Oct 2022 17:41:04 +0000 (12:41 -0500)
committerHarmon <Harmon758@gmail.com>
Wed, 5 Oct 2022 17:41:04 +0000 (12:41 -0500)
tweepy/asynchronous/streaming.py

index 7a19d445562697c435283671e89d6d3e7bdcbc2c..bb7c4903c3db6c3222b21ca930b02042d398a59f 100644 (file)
@@ -61,7 +61,7 @@ class AsyncBaseStream:
         try:
             while error_count <= self.max_retries:
                 try:
-                    if oauth_client:
+                    if oauth_client is not None:
                         url, headers, body = oauth_client.sign(
                             url, http_method=method, headers=headers, body=body
                         )