mirror of
https://github.com/bitwarden/server.git
synced 2025-07-02 16:42:50 -05:00
[AC-2679] Adding a revoked, invited member with Can Manage access does not resolve unmanaged collections (#4397)
* Added check for revoked users * removed check for users as any user status with can manage access should hide the add access badge * updated comments
This commit is contained in:
@ -1,5 +1,4 @@
|
||||
using Bit.Core.Enums;
|
||||
using Bit.Core.Models.Data;
|
||||
using Bit.Core.Models.Data;
|
||||
|
||||
namespace Bit.Infrastructure.EntityFramework.Repositories.Queries;
|
||||
|
||||
@ -47,11 +46,11 @@ public class CollectionAdminDetailsQuery : IQuery<CollectionAdminDetails>
|
||||
from cg in cg_g.DefaultIfEmpty()
|
||||
select new { c, cu, cg };
|
||||
|
||||
// Subqueries to determine if a colection is managed by an active user or group.
|
||||
// Subqueries to determine if a collection is managed by a user or group.
|
||||
var activeUserManageRights = from cu in dbContext.CollectionUsers
|
||||
join ou in dbContext.OrganizationUsers
|
||||
on cu.OrganizationUserId equals ou.Id
|
||||
where ou.Status == OrganizationUserStatusType.Confirmed && cu.Manage
|
||||
where cu.Manage
|
||||
select cu.CollectionId;
|
||||
|
||||
var activeGroupManageRights = from cg in dbContext.CollectionGroups
|
||||
|
Reference in New Issue
Block a user