Skip to content

Commit

Permalink
changes after cr
Browse files Browse the repository at this point in the history
  • Loading branch information
OlimpiaZurek committed Jul 22, 2024
1 parent 1bb4618 commit 82b5016
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/libs/ReportUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1875,12 +1875,14 @@ function getDisplayNameForParticipant(accountID?: number, shouldUseShortForm = f
return '';
}

const login = personalDetails.login ?? '';

// Check if the phone number is already cached
let formattedLogin = phoneNumberCache[personalDetails.login ?? ''];
let formattedLogin = phoneNumberCache[login];
if (!formattedLogin) {
formattedLogin = LocalePhoneNumber.formatPhoneNumber(personalDetails.login ?? '');
formattedLogin = LocalePhoneNumber.formatPhoneNumber(login);
// Store the formatted phone number in the cache
phoneNumberCache[personalDetails.login ?? ''] = formattedLogin;
phoneNumberCache[login] = formattedLogin;
}

// This is to check if account is an invite/optimistically created one
Expand Down

0 comments on commit 82b5016

Please sign in to comment.