Skip to content

Commit

Permalink
moniker
Browse files Browse the repository at this point in the history
  • Loading branch information
mikecot committed Jul 22, 2024
1 parent 4d24311 commit c4da4cd
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/query/classes/MonikerCache.ts
Original file line number Diff line number Diff line change
Expand Up @@ -102,10 +102,12 @@ class ProviderSpecMonikerCache {
return result;
}

const result = Object.entries(monikerToSpecIds)
.map(([moniker, specIds]) => `${moniker} (${specIds.join(', ')})`)
.slice(0, 10)
.join("\n");
const entries = Object.entries(monikerToSpecIds)
.map(([moniker, specIds]) => `${moniker} (${specIds.join(', ')})`);

const result = entries.length > 5
? entries.slice(0, 5).join("\n") + "\n..."
: entries.join("\n");

this.monikerFullDescriptionCache.set(lavaid, result);
return result;
Expand Down

0 comments on commit c4da4cd

Please sign in to comment.