Skip to content

Commit

Permalink
Fix "SyntaxWarning: "is not" with a literal. Did you mean "!="?" (#349)
Browse files Browse the repository at this point in the history
Signed-off-by: Craig Gurnik <cgurnik@gmail.com>
  • Loading branch information
cgurnik committed Jun 23, 2020
1 parent 0af61d9 commit beba99e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion validate/validator.py
Expand Up @@ -889,7 +889,7 @@ def rule_type(field):
str(option_value.double) or str(option_value.uint32) or str(option_value.uint64) or \
str(option_value.bool) or str(option_value.string) or str(option_value.bytes):
return wrapper_template(option_value, name)
elif str(option_value.message) is not "":
elif str(option_value.message) != "":
return message_template(option_value, field.name)
elif str(option_value.any):
return any_template(option_value, name)
Expand Down

0 comments on commit beba99e

Please sign in to comment.