Skip to content

Commit

Permalink
Type fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Aaron Caldwell committed Jan 27, 2021
1 parent dea4be5 commit 5c0f96d
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,12 @@ export function transformResults(
el: LatestEntityLocation & { entityName: string }
) => {
const { entityName, ...locationData } = el;
if (!accu.has(entityName)) {
accu.set(entityName, []);
if (entityName) {
if (!accu.has(entityName)) {
accu.set(entityName, []);
}
accu.get(entityName)!.push(locationData);
}
// @ts-ignore
accu.get(entityName).push(locationData);
return accu;
},
new Map()
Expand Down

0 comments on commit 5c0f96d

Please sign in to comment.