MCPcopy Index your code
hub / github.com/ether/etherpad / getAllAuthorColors

Method getAllAuthorColors

src/node/db/Pad.ts:418–430  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

416 }
417
418 async getAllAuthorColors() {
419 const authorIds = this.getAllAuthors();
420 const returnTable:MapArrayType<string> = {};
421 const colorPalette = authorManager.getColorPalette();
422
423 await Promise.all(
424 authorIds.map((authorId) => authorManager.getAuthorColorId(authorId).then((colorId:string) => {
425 // colorId might be a hex color or an number out of the palette
426 returnTable[authorId] = colorPalette[colorId] || colorId;
427 })));
428
429 return returnTable;
430 }
431
432 getValidRevisionRange(startRev: any, endRev:any) {
433 startRev = parseInt(startRev, 10);

Callers 1

getHtmlMethod · 0.80

Calls 2

getAllAuthorsMethod · 0.95
mapMethod · 0.80

Tested by

no test coverage detected