Skip to content

Commit 607ce1b

Browse files
authored
disable comparison of ACLs for now (#211)
1 parent b7d81ba commit 607ce1b

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

internal/bitwarden/embedded/password_manager_webapi.go

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -475,10 +475,15 @@ func (v *webAPIVault) EditOrganizationCollection(ctx context.Context, obj models
475475

476476
return remoteObj, compareObjects(*resObj, *remoteObj)
477477
} else if v.syncAfterWrite && manageMembership {
478-
// If we had enough permissions to manage memberships, the server will
479-
// always return the collection with the Manage flag set to true.
480-
obj.Manage = true
481-
return resObj, compareObjects(*resObj, obj)
478+
// The server adapts the member list based on the permissions of the
479+
// users. Typically, if we set Manage=false but the user is an owner,
480+
// the server will return the collection with Manage=true and the
481+
// comparison fails. Similarly, if we add the owner of a collection as
482+
// user, it won't be returned in the response as it's an implicit
483+
// member. Instead of managing these edge cases, we'll just not compare
484+
// the objects in this case.
485+
return resObj, err
486+
482487
}
483488
return resObj, err
484489
}

0 commit comments

Comments
 (0)