1
0
mirror of https://github.com/bitwarden/server.git synced 2025-05-23 12:31:06 -05:00

only return eneabled policies by token

This commit is contained in:
Kyle Spearrin 2020-03-02 11:30:44 -05:00
parent 57472c9f82
commit 4a67780b3e

View File

@ -100,7 +100,7 @@ namespace Bit.Api.Controllers
} }
var policies = await _policyRepository.GetManyByOrganizationIdAsync(orgIdGuid); var policies = await _policyRepository.GetManyByOrganizationIdAsync(orgIdGuid);
var responses = policies.Select(p => new PolicyResponseModel(p)); var responses = policies.Where(p => p.Enabled).Select(p => new PolicyResponseModel(p));
return new ListResponseModel<PolicyResponseModel>(responses); return new ListResponseModel<PolicyResponseModel>(responses);
} }