diff --git a/README.md b/README.md index ca785a2..5c1ac77 100644 --- a/README.md +++ b/README.md @@ -77,7 +77,7 @@ Prints: ``` 6 events, 3.59ms -USER_INFO 005000000000AAA user@example.com (0.00ms) +USER_INFO user@example.com : 005000000000AAA (0.00ms) EXECUTION_STARTED (3.53ms) CODE_UNIT_STARTED AccountService.refresh() (3.30ms) METHOD_ENTRY AccountService.loadAccounts() (2.20ms) diff --git a/src/__tests__/Catalog.test.ts b/src/__tests__/Catalog.test.ts index 67a2572..88d80d6 100644 --- a/src/__tests__/Catalog.test.ts +++ b/src/__tests__/Catalog.test.ts @@ -284,6 +284,12 @@ describe('event text', () => { it('reads only the fields a real line states', () => { expect(text('WF_EMAIL_ALERT', 'alert')).toBe('alert'); expect(text('WF_APPROVAL_SUBMITTER', 'Name|005000000000AAA')).toBe('Name : 005000000000AAA'); + expect( + text( + 'USER_INFO', + '[EXTERNAL]|005000000000AAA|user@example.com|Pacific Standard Time|GMT-08:00', + ), + ).toBe('user@example.com : 005000000000AAA'); expect(text('VALIDATION_PASS', '')).toBeNull(); }); diff --git a/src/catalog/catalog.ts b/src/catalog/catalog.ts index 606a6b4..0c6e03a 100644 --- a/src/catalog/catalog.ts +++ b/src/catalog/catalog.ts @@ -1376,7 +1376,7 @@ const ENTRIES: { readonly [T in EventType]: Def } = { fields: ['line', 'userId', 'username', 'timezone', 'timezoneGmt'], debugCategory: 'apexCode', level: 'ERROR', - text: joinPresent(' ', 'userId', 'username'), + text: joinPresent(' : ', 'username', 'userId'), }, USER_MODE_PERMSET_APPLIED: { debugCategory: 'database', level: 'FINE' }, VALIDATION_ERROR: {