Skip to content

Commit

Permalink
Merge pull request Expensify#46665 from callstack-internal/perf/get-l…
Browse files Browse the repository at this point in the history
…ogins-by-account-ids
  • Loading branch information
blimpich committed Aug 1, 2024
2 parents 88acdd4 + b2cdfdb commit a3339ef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/libs/PersonalDetailsUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ function getAccountIDsByLogins(logins: string[]): number[] {
*/
function getLoginsByAccountIDs(accountIDs: number[]): string[] {
return accountIDs.reduce((foundLogins: string[], accountID) => {
const currentDetail: Partial<PersonalDetails> = personalDetails.find((detail) => Number(detail?.accountID) === Number(accountID)) ?? {};
const currentDetail: Partial<PersonalDetails> = allPersonalDetails?.[accountID] ?? {};
if (currentDetail.login) {
foundLogins.push(currentDetail.login);
}
Expand Down

0 comments on commit a3339ef

Please sign in to comment.