Skip to content

Commit 1152dd3

Browse files
committed
small nit changes
1 parent c40ebb7 commit 1152dd3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

labelbox/schema/ontology_generator.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def asdict(self) -> Dict[str, Any]:
2626
"featureSchemaId": self.feature_schema_id,
2727
"label": self.label,
2828
"value": self.value,
29-
"options": [c.asdict() for c in self.options]}
29+
"options": [o.asdict() for o in self.options]}
3030

3131
@classmethod
3232
def from_dict(cls, dictionary: Dict[str,Any]):
@@ -38,7 +38,7 @@ def from_dict(cls, dictionary: Dict[str,Any]):
3838
for o in dictionary.get("options", [])])
3939

4040
def add_option(self, option: 'Classification') -> 'Classification':
41-
if option.instructions in (c.instructions for c in self.options):
41+
if option.instructions in (o.instructions for o in self.options):
4242
raise InconsistentOntologyException(
4343
f"Duplicate nested classification '{option.instructions}' "
4444
f"for option '{self.label}'")

0 commit comments

Comments
 (0)