Fixes bug in detecting empty options (see issue #132 on github)

This commit is contained in:
Issac Goldstand
2013-05-08 12:05:32 +03:00
parent 936ad4da8e
commit 8c12c948d9
2 changed files with 5 additions and 1 deletions

View File

@@ -30,7 +30,7 @@ function DateRollingFileStream(filename, pattern, options, now) {
filename = filename + this.lastTimeWeWroteSomething;
}
delete options.alwaysIncludePattern;
if (options === {}) {
if (Object.keys(options).length === 0) {
options = null;
}
}