Skip to content

Commit

Permalink
fix(resource-explorer): only use alias to query if present
Browse files Browse the repository at this point in the history
  • Loading branch information
corteggiano committed Sep 14, 2024
1 parent aaa4a8d commit ca35aee
Showing 1 changed file with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,18 @@ function createEntries<DataStream extends DataStreamResource>(
const entries = dataStreams.map((dataStream) => {
const entryId = createEntryId(dataStream);

return {
const baseEntry = {
dataStream,
entryId,
};

if (dataStream.alias) {
return { ...baseEntry, propertyAlias: dataStream.alias };
}

return {
...baseEntry,
assetId: dataStream.assetId,
propertyAlias: dataStream.alias,
propertyId: dataStream.propertyId,
};
});
Expand Down

0 comments on commit ca35aee

Please sign in to comment.