We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2608c61 commit 098040dCopy full SHA for 098040d
1 file changed
src/utils.ts
@@ -163,7 +163,14 @@ function rewriteAuthIfMatches(
163
): PermissionLevelType {
164
if (permissionLevel.equals(auth)) {
165
return PermissionLevel.from({
166
- actor: auth.actor,
+ actor: permissionLevel.actor,
167
+ permission: newPermission,
168
+ })
169
+ }
170
+ // Also rewrite PlaceholderAuth to use the session's actor with the new permission
171
+ if (PlaceholderAuth.equals(auth)) {
172
+ return PermissionLevel.from({
173
174
permission: newPermission,
175
})
176
}
0 commit comments