Skip to content

Commit 22b7847

Browse files
committed
Fix typo
1 parent 45c2bfb commit 22b7847

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

infrahub_sdk/node/node.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1029,7 +1029,7 @@ def _get_relationship_one(self, name: str) -> RelatedNode:
10291029
raise ResourceNotDefinedError(message=f"The node doesn't have a cardinality=one relationship for {name}")
10301030

10311031
async def get_flat_value(self, key: str, separator: str = "__") -> Any:
1032-
"""Query recursively an value defined in a flat notation (string), on a hierarchy of objects
1032+
"""Query recursively a value defined in a flat notation (string), on a hierarchy of objects
10331033
10341034
Examples:
10351035
name__value
@@ -1053,7 +1053,7 @@ async def get_flat_value(self, key: str, separator: str = "__") -> Any:
10531053

10541054
if rel.cardinality != RelationshipCardinality.ONE:
10551055
raise ValueError(
1056-
f"Unable to lookup flat value for relationship of cardinality {RelationshipCardinality.MANY}"
1056+
f"Can only look up flat value for relationships of cardinality {RelationshipCardinality.ONE}"
10571057
)
10581058

10591059
related_node: RelatedNode = getattr(self, first)
@@ -1655,7 +1655,7 @@ def _get_relationship_one(self, name: str) -> RelatedNode | RelatedNodeSync:
16551655
raise ResourceNotDefinedError(message=f"The node doesn't have a cardinality=one relationship for {name}")
16561656

16571657
def get_flat_value(self, key: str, separator: str = "__") -> Any:
1658-
"""Query recursively an value defined in a flat notation (string), on a hierarchy of objects
1658+
"""Query recursively a value defined in a flat notation (string), on a hierarchy of objects
16591659
16601660
Examples:
16611661
name__value
@@ -1679,7 +1679,7 @@ def get_flat_value(self, key: str, separator: str = "__") -> Any:
16791679

16801680
if rel.cardinality != RelationshipCardinality.ONE:
16811681
raise ValueError(
1682-
f"Unable to lookup flat value for relationship of cardinality {RelationshipCardinality.MANY}"
1682+
f"Can only look up flat value for relationships of cardinality {RelationshipCardinality.ONE}"
16831683
)
16841684

16851685
related_node: RelatedNodeSync = getattr(self, first)

0 commit comments

Comments
 (0)