Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitef15908

Browse files
committed
fix rbac merge woes
1 parent5c6344f commitef15908

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

‎coderd/rbac/builtin.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -398,12 +398,12 @@ func roleSplit(role string) (name string, orgID string, err error) {
398398
// and actions a bit easier.
399399
funcpermissions(permsmap[string][]Action) []Permission {
400400
list:=make([]Permission,0,len(perms))
401-
forobjectType,actions:=rangeperms {
401+
fork,actions:=rangeperms {
402402
for_,act:=rangeactions {
403403
act:=act
404404
list=append(list,Permission{
405405
Negate:false,
406-
ResourceType:objectType,
406+
ResourceType:k,
407407
Action:act,
408408
})
409409
}

‎coderd/rbac/scopes.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ var builtinScopes map[Scope]Role = map[Scope]Role{
1919
ScopeAll: {
2020
Name:fmt.Sprintf("Scope_%s",ScopeAll),
2121
DisplayName:"All operations",
22-
Site:permissions(map[Object][]Action{
23-
ResourceWildcard: {WildcardSymbol},
22+
Site:permissions(map[string][]Action{
23+
ResourceWildcard.Type: {WildcardSymbol},
2424
}),
2525
Org:map[string][]Permission{},
2626
User: []Permission{},
@@ -29,8 +29,8 @@ var builtinScopes map[Scope]Role = map[Scope]Role{
2929
ScopeApplicationConnect: {
3030
Name:fmt.Sprintf("Scope_%s",ScopeApplicationConnect),
3131
DisplayName:"Ability to connect to applications",
32-
Site:permissions(map[Object][]Action{
33-
ResourceWorkspaceApplicationConnect: {ActionCreate},
32+
Site:permissions(map[string][]Action{
33+
ResourceWorkspaceApplicationConnect.Type: {ActionCreate},
3434
}),
3535
Org:map[string][]Permission{},
3636
User: []Permission{},

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp