Comparing version 0.3.1 to 0.3.2
@@ -38,3 +38,3 @@ "use strict"; | ||
this.addCache(s); | ||
if (this.logLevel > level.error) | ||
if (this.logLevel >= level.error) | ||
return Debux.consoleLog(this.constructMessage(chalk_1.default.red(s), "error", options)); | ||
@@ -44,3 +44,3 @@ } | ||
this.addCache(s); | ||
if (this.logLevel > level.warning) | ||
if (this.logLevel >= level.warning) | ||
return Debux.consoleLog(this.constructMessage(chalk_1.default.yellow(s), "warn", options)); | ||
@@ -50,3 +50,3 @@ } | ||
this.addCache(s); | ||
if (this.logLevel > level.info) | ||
if (this.logLevel >= level.info) | ||
return Debux.consoleLog(this.constructMessage(s, "info", options)); | ||
@@ -53,0 +53,0 @@ } |
@@ -8,3 +8,3 @@ "use strict"; | ||
const __1 = __importDefault(require("..")); | ||
const debug = __1.default({ maxCacheSize: 10, logLevel: 4 }); | ||
const debug = __1.default({ maxCacheSize: 10, logLevel: 3 }); | ||
debug.log("this is a log", { | ||
@@ -11,0 +11,0 @@ process: "process", |
{ | ||
"name": "debux", | ||
"version": "0.3.1", | ||
"version": "0.3.2", | ||
"description": "Easy-to-use library for debugging your code", | ||
@@ -5,0 +5,0 @@ "main": "build/index.js", |
@@ -55,3 +55,3 @@ import chalk from "chalk"; | ||
this.addCache(s); | ||
if (this.logLevel > level.error) | ||
if (this.logLevel >= level.error) | ||
return Debux.consoleLog(this.constructMessage(chalk.red(s), "error", options)); | ||
@@ -62,3 +62,3 @@ } | ||
this.addCache(s); | ||
if (this.logLevel > level.warning) | ||
if (this.logLevel >= level.warning) | ||
return Debux.consoleLog(this.constructMessage(chalk.yellow(s), "warn", options)); | ||
@@ -69,3 +69,3 @@ } | ||
this.addCache(s); | ||
if (this.logLevel > level.info) | ||
if (this.logLevel >= level.info) | ||
return Debux.consoleLog(this.constructMessage(s, "info", options)); | ||
@@ -72,0 +72,0 @@ } |
//@ts-ignore | ||
import debux from ".."; | ||
const debug = debux({ maxCacheSize: 10, logLevel: 4 }); | ||
const debug = debux({ maxCacheSize: 10, logLevel: 3 }); | ||
@@ -6,0 +6,0 @@ debug.log("this is a log", { |
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
11809