Commit 1e986f1
committed
fix: include default roles when adding custom viewer role to org plugin
Better Auth's hasPermission uses `options.roles || defaultRoles`, so
passing only `{ viewer }` made the built-in owner/admin/member roles
unresolvable, causing "not allowed to invite" errors for owners.1 parent cfa4eb6 commit 1e986f1
1 file changed
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
4 | 5 | | |
5 | 6 | | |
6 | 7 | | |
| |||
82 | 83 | | |
83 | 84 | | |
84 | 85 | | |
| 86 | + | |
85 | 87 | | |
86 | 88 | | |
87 | 89 | | |
| |||
0 commit comments