From e36faba091daf4fac2f9af8f0f03a3888087acad Mon Sep 17 00:00:00 2001 From: Denys Fedoryshchenko Date: Tue, 7 Nov 2023 07:00:37 +0200 Subject: [PATCH] main.py: Remove reference to .profile from user Due updates to data model, .profile part in collection is removed. Updating code accordingly. Signed-off-by: Denys Fedoryshchenko --- api/main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/main.py b/api/main.py index 239179b6..7d686950 100644 --- a/api/main.py +++ b/api/main.py @@ -556,7 +556,7 @@ async def put_node(node_id: str, node: Node, async def _set_node_ownership_recursively(user: User, hierarchy: Hierarchy): """Set node ownership information for a hierarchy of nodes""" if not hierarchy.node.owner: - hierarchy.node.owner = user.profile.username + hierarchy.node.owner = user.username for node in hierarchy.child_nodes: await _set_node_ownership_recursively(user, node)