1
0
mirror of https://github.com/bitwarden/server.git synced 2024-11-22 12:15:36 +01:00

return empty policies array if none

This commit is contained in:
Kyle Spearrin 2020-03-12 15:05:46 -04:00
parent 0f9ec8d64f
commit 7dc959c058

View File

@ -28,7 +28,7 @@ namespace Bit.Core.Models.Api
Collections = collections?.Select(
c => new CollectionDetailsResponseModel(c)) ?? new List<CollectionDetailsResponseModel>();
Domains = excludeDomains ? null : new DomainsResponseModel(user, false);
Policies = policies?.Select(p => new PolicyResponseModel(p));
Policies = policies?.Select(p => new PolicyResponseModel(p)) ?? new List<PolicyResponseModel>();
}
public ProfileResponseModel Profile { get; set; }