Skip to content

Commit 4c5b4ee

Browse files
committed
sql 2.0
1 parent bfaad56 commit 4c5b4ee

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

services/web/server/src/simcore_service_webserver/functions/_functions_repository.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1100,7 +1100,7 @@ async def get_user_permissions(
11001100
# Combine permissions for all groups the user belongs to
11011101
result = await conn.stream(
11021102
access_rights_table.select()
1103-
.with_only_columns(cols)
1103+
.with_only_columns(*cols)
11041104
.where(
11051105
getattr(access_rights_table.c, f"{object_type}_uuid") == object_id,
11061106
access_rights_table.c.product_name == product_name,
@@ -1114,9 +1114,9 @@ async def get_user_permissions(
11141114

11151115
# Combine permissions across all rows
11161116
combined_permissions = {
1117-
"read": any(row["read"] for row in rows),
1118-
"write": any(row["write"] for row in rows),
1119-
"execute": any(row["execute"] for row in rows),
1117+
"read": any(row.read for row in rows),
1118+
"write": any(row.write for row in rows),
1119+
"execute": any(row.execute for row in rows),
11201120
}
11211121

11221122
return FunctionAccessRightsDB.model_validate(combined_permissions)

0 commit comments

Comments
 (0)