File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- /* eslint-disable no-console */
2-
31import path from 'node:path' ;
42
53import { ValidationPipe } from '@douglasneuroinformatics/libnest/core' ;
@@ -21,12 +19,12 @@ async function bootstrap() {
2119
2220 const configurationService = app . get ( ConfigurationService ) ;
2321
24- app . useLogger (
25- new JSONLogger ( null , {
26- debug : configurationService . get ( 'DEBUG' ) ,
27- verbose : configurationService . get ( 'VERBOSE' )
28- } )
29- ) ;
22+ const logger = new JSONLogger ( null , {
23+ debug : configurationService . get ( 'DEBUG' ) ,
24+ verbose : configurationService . get ( 'VERBOSE' )
25+ } ) ;
26+
27+ app . useLogger ( logger ) ;
3028
3129 app . enableCors ( ) ;
3230 app . enableVersioning ( {
@@ -44,7 +42,7 @@ async function bootstrap() {
4442
4543 await app . listen ( port ) ;
4644
47- console . log ( `Application is running on: ${ await app . getUrl ( ) } ` ) ;
45+ logger . log ( `Application is running on: ${ await app . getUrl ( ) } ` ) ;
4846}
4947
5048void bootstrap ( ) ;
You can’t perform that action at this time.
0 commit comments