Skip to content

Commit 4ef9988

Browse files
authored
Fixed SyntaxWarning in py3.8
This prevents the following warning from appearing on Python 3.8: ``` /usr/local/lib/python3.8/site-packages/pusher/notification_client.py:45: SyntaxWarning: "is" with a literal. Did you mean "=="? if len(interests) is 0: ```
1 parent 8f32b3c commit 4ef9988

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pusher/notification_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ def notify(self, interests, notification):
4242
if not isinstance(interests, list) and not isinstance(interests, set):
4343
raise TypeError("Interests must be a list or a set")
4444

45-
if len(interests) is 0:
45+
if len(interests) == 0:
4646
raise ValueError("Interests must not be empty")
4747

4848
if not isinstance(notification, dict):

0 commit comments

Comments
 (0)