pylint plugin: reduce indentation
@@ -95,9 +95,13 @@ def transform(cls):
"""
if cls.name in CLASS_NAME_BLACKLIST:
+ # class looks like an API model class, but it isn't.
+ return
+
+ if not cls.name.endswith("API") and "schema" not in cls.locals:
+ # class does not look like an API model class.
return
- if cls.name.endswith("API") or "schema" in cls.locals:
# This is a class which defines attributes in "schema" variable using json schema.
# Those attributes are then assigned during run time inside the constructor
schema_dict_node = next(cls.igetattr("schema"))
