Skip to content

Commit

Permalink
Clean up job
Browse files Browse the repository at this point in the history
  • Loading branch information
i-vukman committed Oct 13, 2023
1 parent 50777cd commit f6630f6
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,9 @@ public async Task ExecuteAsync(ImportCelebritiesPageJobData data)
var limit = pageRequest.Limit;
var offset = pageRequest.Offset;

return (await _httpClient.GetCelebritiesPageAsync(occupationId, nationalityId, limit, offset))!.Results!.Bindings
var celebritiesPageResponse = await _httpClient.GetCelebritiesPageAsync(occupationId, nationalityId, limit, offset);

return celebritiesPageResponse!.Results!.Bindings
.Where(x => !string.IsNullOrWhiteSpace(x.ItemLabel.Value.ToRemovedWhitespace().ToRemovedPunctuation()))
.DistinctBy(x => x.Item.Value)
.ToDictionary(k => k.Item.Value, v => v);
Expand Down

0 comments on commit f6630f6

Please sign in to comment.