Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
teo-milea committed Oct 14, 2024
1 parent 1fef3ed commit 331881e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/syft/src/syft/service/migration/migration_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -500,7 +500,7 @@ def reset_and_restore(
return SyftSuccess(message="Database reset successfully.")

@service_method(
path="sync._get_object",
path="migration._get_object",
name="_get_object",
roles=DATA_SCIENTIST_ROLE_LEVEL,
)
Expand All @@ -514,7 +514,7 @@ def _get_object(
)

@service_method(
path="sync._update_object",
path="migration._update_object",
name="_update_object",
roles=ADMIN_ROLE_LEVEL,
)
Expand Down
4 changes: 3 additions & 1 deletion packages/syft/src/syft/types/syft_object.py
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,9 @@ def refresh(self) -> None:
api = self._get_api()
except Exception as _:
return
new_object = api.services.sync._get_object(uid=self.id, object_type=type(self))
new_object = api.services.migration._get_object(
uid=self.id, object_type=type(self)
)
if type(new_object) == type(self):
self.__dict__.update(new_object.__dict__)

Expand Down

0 comments on commit 331881e

Please sign in to comment.