Skip to content

Commit 9010163

Browse files
committed
only add filename in debug
1 parent 91a3d0b commit 9010163

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

OpenFlow/src/Logger.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,10 @@ export class Logger {
1010
if (info instanceof Error || info.stack) {
1111
return `${info.timestamp} [${info.level}] ${info.message} \n ${info.stack}`;
1212
}
13-
return `${info.timestamp} [${Logger.getLabel()}][${info.level}] ${info.message}`;
13+
if (Config.NODE_ENV == "development") {
14+
return `${info.timestamp} [${Logger.getLabel()}][${info.level}] ${info.message}`;
15+
}
16+
return `${info.timestamp} [${info.level}] ${info.message}`;
1417
});
1518
static getLabel = function () {
1619
let e = new Error();

0 commit comments

Comments
 (0)