mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-13 23:07:34 +00:00
fix: use correct the userID column name in permissions v2 check (#10467)
# Which Problems Are Solved When `Permission Check V2` is enabled, calls to the `ListPasskeys` and `ListAuthenticationFactors` APIs fail with the following error: ``` ERROR: missing FROM-clause entry for table "users14" ``` # How the Problems Are Solved By using the right UserID column (`projections.user_auth_methods5.user_id`) in the permission clause in the `userAuthMethod` query # Additional Changes N/A # Additional Context - Closes #10386
This commit is contained in:
@@ -112,7 +112,7 @@ func userAuthMethodPermissionCheckV2(ctx context.Context, query sq.SelectBuilder
|
||||
ctx,
|
||||
UserAuthMethodColumnResourceOwner,
|
||||
domain.PermissionUserRead,
|
||||
OwnedRowsPermissionOption(UserIDCol),
|
||||
OwnedRowsPermissionOption(UserAuthMethodColumnUserID),
|
||||
)
|
||||
return query.JoinClause(join, args...)
|
||||
}
|
||||
|
Reference in New Issue
Block a user