Skip to content

Commit 9e99ae4

Browse files
committed
Fix lint
1 parent b0d270f commit 9e99ae4

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

libs/labelbox/src/labelbox/schema/ontology.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,9 @@ def from_dict(cls, dictionary: Dict[str, Any]) -> Dict[str, Any]:
145145
]
146146
if dictionary.get("attributes")
147147
else None,
148-
constraints=dictionary.get("constraints", None) if tool == Tool.Type.RELATIONSHIP else None,
148+
constraints=dictionary.get("constraints", None)
149+
if tool == Tool.Type.RELATIONSHIP
150+
else None,
149151
)
150152

151153
def asdict(self) -> Dict[str, Any]:
@@ -162,7 +164,9 @@ def asdict(self) -> Dict[str, Any]:
162164
"attributes": [a.asdict() for a in self.attributes]
163165
if self.attributes is not None
164166
else None,
165-
"constraints": self.constraints if self.constraints is not None else None,
167+
"constraints": self.constraints
168+
if self.constraints is not None
169+
else None,
166170
}
167171

168172
def add_classification(self, classification: Classification) -> None:

0 commit comments

Comments
 (0)