diff --git a/__tests__/ExpensiMark-HTMLToText-test.js b/__tests__/ExpensiMark-HTMLToText-test.js index 6757803b..7d150149 100644 --- a/__tests__/ExpensiMark-HTMLToText-test.js +++ b/__tests__/ExpensiMark-HTMLToText-test.js @@ -160,6 +160,10 @@ test('Mention user html to text', () => { testString = ''; expect(parser.htmlToText(testString, extras)).toBe('@user@domain.com'); + + extras.accountIDToName['1234'] = '+251924892738@expensify.sms'; + testString = ''; + expect(parser.htmlToText(testString, extras)).toBe('@+251924892738'); }); test('Mention report html to text', () => { diff --git a/lib/ExpensiMark.ts b/lib/ExpensiMark.ts index 48e05b0d..fc70990a 100644 --- a/lib/ExpensiMark.ts +++ b/lib/ExpensiMark.ts @@ -780,7 +780,7 @@ export default class ExpensiMark { ExpensiMark.Log.alert('[ExpensiMark] Missing account name', {accountID: g1}); return '@Hidden'; } - return `@${extras.accountIDToName?.[g1]}`; + return `@${Str.removeSMSDomain(extras.accountIDToName?.[g1] ?? '')}`; }, }, {