Skip to content
This repository has been archived by the owner on Sep 18, 2021. It is now read-only.

Consents are now loaded sequentially. #3655

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions source/Core/Services/Default/AggregateConsentStore.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,11 @@ public AggregatePermissionsStore(params IPermissionsStore[] stores)

public async Task<IEnumerable<Consent>> LoadAllAsync(string subject)
{
var result =
await stores
.Select(x => x.LoadAllAsync(subject))
.Aggregate(async (t1, t2) => (await t1).Union(await t2));
List<Consent> result = new List<Consent>();
foreach (IPermissionsStore store in stores)
{
result.AddRange(await store.LoadAllAsync(subject).ConfigureAwait(false));
}

var query =
from item in result
Expand Down