Skip to content

Commit

Permalink
Removed psudocode comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Dominic NEED authored and Dominic NEED committed Nov 9, 2023
1 parent 9ed89e5 commit 0318e73
Showing 1 changed file with 2 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -64,16 +64,13 @@ public async Task<List<Establishment>> GetByUrns(int[] urns, CancellationToken c
}

public async Task<List<Establishment>> GetByTrust(long? trustId, CancellationToken cancellationToken)
{

// Change the select to cast to long if necessary
{
var establishmentIds = await context.EducationEstablishmentTrusts
.Where(eet => eet.FK_Trust == Convert.ToInt32(trustId))
.Select(eet => (long)eet.FK_EducationEstablishment)
.ToListAsync(cancellationToken)
.ConfigureAwait(false);

// And ensure there is no conversion if SK is long

var establishments = await DefaultIncludes()
.Where(e => establishmentIds.Contains(e.SK))
.ToListAsync(cancellationToken)
Expand Down

0 comments on commit 0318e73

Please sign in to comment.