Skip to content

Commit 1d9ad6f

Browse files
fix(ui): change password button is hidden when user has full field access (#12988)
1 parent 30fc7e3 commit 1d9ad6f

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

packages/ui/src/views/Edit/Auth/index.tsx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,12 +69,13 @@ export const Auth: React.FC<Props> = (props) => {
6969
})
7070

7171
if (operation === 'create') {
72-
showPasswordFields = typeof passwordPermissions === 'object' && passwordPermissions.create
72+
showPasswordFields =
73+
passwordPermissions === true ||
74+
(typeof passwordPermissions === 'object' && passwordPermissions.create)
7375
} else {
7476
showPasswordFields =
75-
typeof passwordPermissions === 'object' &&
76-
passwordPermissions.read &&
77-
passwordPermissions.update
77+
passwordPermissions === true ||
78+
(typeof passwordPermissions === 'object' && passwordPermissions.update)
7879
}
7980
}
8081

0 commit comments

Comments
 (0)