Refactor firstNameMap creation in FalukantService for improved efficiency
- Simplified the construction of firstNameMap by removing unnecessary spread operator, enhancing performance and readability.
This commit is contained in:
@@ -2987,7 +2987,7 @@ class FalukantService extends BaseService {
|
||||
]);
|
||||
|
||||
// Erstelle Maps für schnellen Zugriff
|
||||
const firstNameMap = new Map([...firstNames, ...childFirstNames].map(fn => [fn.id, fn.name]));
|
||||
const firstNameMap = new Map(firstNames.map(fn => [fn.id, fn.name]));
|
||||
const lastNameMap = new Map(lastNames.map(ln => [ln.id, ln.name]));
|
||||
const titleMap = new Map(titles.map(t => [t.id, t.labelTr]));
|
||||
const moodMap = new Map(moods.map(m => [m.id, m.tr]));
|
||||
|
||||
Reference in New Issue
Block a user