File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ export const dateDifference = (start?: Date): string => {
5050 const newPart = Math . floor ( acc . ms / frame ) ;
5151 const newMs = acc . ms - newPart * frame ;
5252 return {
53- ms : acc . ms - newMs ,
53+ ms : newMs ,
5454 parts : [ ...acc . parts , newPart ]
5555 } ;
5656 } ,
Original file line number Diff line number Diff line change @@ -23,7 +23,8 @@ export const initUptime = (host: string): void => {
2323
2424 logger . warn ( 'Initializing the status handler' ) ;
2525 startDate = new Date ( ) ;
26- const statusUrl = `https://${ host } /status` ;
26+ const protocol = host . includes ( 'localhost' ) ? 'http' : 'https' ;
27+ const statusUrl = `${ protocol } ://${ host } /status` ;
2728 checkStatus ( statusUrl ) ;
2829 timerHandler = setInterval ( ( ) => {
2930 logger . warn ( 'Check the health status' , statusUrl ) ;
You can’t perform that action at this time.
0 commit comments