Merge pull request #1556 from croneter/py3-fix-regression

Fix Regression: AttributeError
This commit is contained in:
croneter 2021-07-25 11:04:53 +02:00 committed by GitHub
commit 6040e40a7a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -106,6 +106,8 @@ class Section(object):
def __eq__(self, section):
"""Sections compare equal if their section_id, name and plex_type (first prio) OR section_type (if there is no plex_type is set) compare equal.
"""
if not isinstance(section, Section):
return False
return (self.section_id == section.section_id and
self.name == section.name and
(self.plex_type == section.plex_type if self.plex_type else