File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -29,7 +29,10 @@ export default async function bootstrap(apiPort?: number): Promise<IApp> {
29
29
await migrateHomeFolder ( ) && await removeOldFolders ( ) ;
30
30
}
31
31
32
- const { port, host } = serverConfig ;
32
+ if ( apiPort ) {
33
+ serverConfig . port = apiPort ;
34
+ }
35
+
33
36
const logger = WinstonModule . createLogger ( LOGGER_CONFIG ) ;
34
37
35
38
const options : NestApplicationOptions = {
@@ -75,7 +78,9 @@ export default async function bootstrap(apiPort?: number): Promise<IApp> {
75
78
76
79
const logFileProvider = app . get ( LogFileProvider ) ;
77
80
78
- await app . listen ( apiPort || port , host ) ;
81
+ const { port, host } = serverConfig ;
82
+
83
+ await app . listen ( port , host ) ;
79
84
logger . log ( {
80
85
message : `Server is running on http(s)://${ host } :${ port } ` ,
81
86
context : 'bootstrap' ,
You can’t perform that action at this time.
0 commit comments