mirror of https://github.com/nocturn9x/nimd.git
Slightly changed CRITICAL's error message format
This commit is contained in:
parent
5c2515c3a7
commit
b01da7eada
|
@ -109,9 +109,11 @@ proc getDefaultLogger*(): Logger =
|
|||
proc logFatal(self: LogHandler, logger: Logger, message: string) =
|
||||
setForegroundColor(fgBlack)
|
||||
setBackgroundColor(bgRed)
|
||||
stderr.writeLine(&"""[{fromUnix(getTime().toUnixFloat().int).format("d/M/yyyy HH:mm:ss")} - FATAL] {message}""")
|
||||
setForegroundColor(fgDefault)
|
||||
stderr.write(&"""[{fromUnix(getTime().toUnixFloat().int).format("d/M/yyyy HH:mm:ss")} - FATAL]""")
|
||||
setForegroundColor(fgRed)
|
||||
setBackgroundColor(bgDefault)
|
||||
stderr.writeline(&" {message}")
|
||||
setForegroundColor(fgDefault)
|
||||
|
||||
result = newLogger()
|
||||
result.addHandler(createHandler(logTrace, LogLevel.Trace))
|
||||
|
|
Loading…
Reference in New Issue