Don't raise exception for false

This commit is contained in:
Cristina Muñoz 2020-06-02 10:45:16 -07:00
parent 9583642d87
commit 92ca536279
1 changed files with 2 additions and 2 deletions

View File

@ -26,10 +26,10 @@ class FormatControl(object):
def __eq__(self, other):
# type: (object) -> bool
if not isinstance(other, self.__class__):
return NotImplemented
return False
if self.__slots__ != other.__slots__:
return NotImplemented
return False
return all(
getattr(self, k) == getattr(other, k)