Skip to content

Commit

Permalink
Make PropertyId::load_view_or_container_id private
Browse files Browse the repository at this point in the history
  • Loading branch information
erlendvollset committed Dec 20, 2023
1 parent 7dd2c5c commit 76fe211
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cognite/client/data_classes/data_modeling/ids.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,12 +152,12 @@ class PropertyId(CogniteObject):
@classmethod
def _load(cls, resource: dict[str, Any], cognite_client: CogniteClient | None = None) -> Self:
return cls(
source=cls.load_view_or_container_id(resource["source"]),
source=cls.__load_view_or_container_id(resource["source"]),
property=resource["identifier"],
)

@staticmethod
def load_view_or_container_id(view_or_container_id: dict[str, Any]) -> ViewId | ContainerId:
def __load_view_or_container_id(view_or_container_id: dict[str, Any]) -> ViewId | ContainerId:
if "type" in view_or_container_id and view_or_container_id["type"] in {"view", "container"}:
if view_or_container_id["type"] == "view":
return ViewId.load(view_or_container_id)
Expand Down

0 comments on commit 76fe211

Please sign in to comment.