Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit a202178

Browse files
committed
fixup! Update migration to promote either admin
1 parent 3e6ae07 commit a202178

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

coderd/database/migrations/000034_remove_admin_role.up.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ UPDATE
1414
users
1515
SET
1616
-- Replace 'admin' role with 'template-admin' and 'user-admin'
17-
rbac_roles = array_cat(array_remove(users.rbac_roles, 'admin'), ARRAY ['template-admin', 'user-admin'])
17+
rbac_roles = array_cat(array_remove(rbac_roles, 'admin'), ARRAY ['template-admin', 'user-admin'])
1818
WHERE
1919
-- Only on existing admins
2020
'admin' = ANY(rbac_roles);

0 commit comments

Comments
 (0)