Skip to content

Commit 9841d3a

Browse files
committed
Rename constant adding millisecond unit
1 parent 470d89b commit 9841d3a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/constants.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,4 +73,4 @@ export const INSPECT_DEBUGGER_PORT = 5858
7373

7474
export const cancellableMethods = new Set(['GET', 'OPTIONS', 'HEAD'])
7575

76-
export const LOG_CLIENT_INIT_TIMEOUT = 5000
76+
export const LOG_CLIENT_INIT_TIMEOUT_MS = 5000

src/service/logger/logger.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { APP, LOG_CLIENT_INIT_TIMEOUT } from '../../constants'
1+
import { APP, LOG_CLIENT_INIT_TIMEOUT_MS } from '../../constants'
22
import { cleanError } from '../../utils/error'
33
import { cleanLog } from '../../utils/log'
44
import { LogClient } from '@vtex/diagnostics-nodejs/dist/types';
@@ -43,7 +43,7 @@ export class Logger {
4343
this.clientInitPromise = (async () => {
4444
try {
4545
const timeoutPromise = new Promise<never>((_, reject) => {
46-
setTimeout(() => reject(new Error('Log client initialization timeout')), LOG_CLIENT_INIT_TIMEOUT);
46+
setTimeout(() => reject(new Error('Log client initialization timeout')), LOG_CLIENT_INIT_TIMEOUT_MS);
4747
});
4848

4949
this.logClient = await Promise.race([

0 commit comments

Comments
 (0)