@4lch4/logger
Advanced tools
Comparing version 1.6.0 to 1.6.1
@@ -8,3 +8,3 @@ import { ILogger, ILoggerOpts } from './interfaces'; | ||
debug(msg: string | Object): void; | ||
error(msg: string | Error, ...extra: any[]): void; | ||
error(msg: string | Error | unknown, ...extra: any[]): void; | ||
success(msg: string): void; | ||
@@ -11,0 +11,0 @@ log(msg: string, level: any): void; |
@@ -29,2 +29,5 @@ "use strict"; | ||
} | ||
else if (msg instanceof String) { | ||
console.log(this.formatter.formatMsg(msg, interfaces_1.Level.error)); | ||
} | ||
else { | ||
@@ -31,0 +34,0 @@ console.log(this.formatter.formatMsg(msg, interfaces_1.Level.error)); |
@@ -27,3 +27,3 @@ "use strict"; | ||
time: this.getUTCTime(), | ||
host: os_1.hostname(), | ||
host: (0, os_1.hostname)(), | ||
pid: process.pid, | ||
@@ -49,6 +49,6 @@ level, | ||
getUTCTime() { | ||
return dayjs_1.default().format(_1.DefaultDayJSFormats.utcMillisecondsFormat); | ||
return (0, dayjs_1.default)().format(_1.DefaultDayJSFormats.utcMillisecondsFormat); | ||
} | ||
getPrettyTime() { | ||
return dayjs_1.default().format(_1.DefaultDayJSFormats.prettyFormat); | ||
return (0, dayjs_1.default)().format(_1.DefaultDayJSFormats.prettyFormat); | ||
} | ||
@@ -55,0 +55,0 @@ } |
{ | ||
"name": "@4lch4/logger", | ||
"displayName": "Logger", | ||
"version": "1.6.0", | ||
"version": "1.6.1", | ||
"description": "A small utility for logging to console within NodeJS/TypeScript applications.", | ||
@@ -6,0 +6,0 @@ "main": "dist/index.js", |
@@ -6,2 +6,1 @@ export * from './IColorOpts' | ||
export * from './LogFormat' | ||
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
34633
416