10000 fixed small issue that could occur with wrong evaluated parameters · rboss/log4js-node@5c75ba9 · GitHub
[go: up one dir, main page]

Skip to content

Commit 5c75ba9

Browse files
committed
fixed small issue that could occur with wrong evaluated parameters
1 parent bec0d05 commit 5c75ba9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/layouts.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ function patternLayout (pattern, tokens) {
236236
replacement = "%";
237237
break;
238238
case "x":
239-
if(tokens[specifier]) {
239+
if(typeof(tokens[specifier]) !== 'undefined') {
240240
if(typeof(tokens[specifier]) === 'function') {
241241
replacement = tokens[specifier]();
242242
} else {

0 commit comments

Comments
 (0)
0