Merge pull request #826 from croneter/fix-ne

Fix unequality when comparing sections
This commit is contained in:
croneter 2019-04-14 14:55:06 +02:00 committed by GitHub
commit 4dcf057631
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -111,7 +111,9 @@ class Section(object):
return (self.section_id == section.section_id and return (self.section_id == section.section_id and
self.name == section.name and self.name == section.name and
self.section_type == section.section_type) self.section_type == section.section_type)
__ne__ = not __eq__
def __ne__(self, section):
return not self == section
@property @property
def section_id(self): def section_id(self):