Closed
Description
For example, let's say I have the following:
const debug = require("debug");
const foobarDebug = debug("foo:bar");
debug.enable("foo:*");
console.log("debug.enabled('foo:bar')?", debug.enabled("foo:bar"));
console.log("foobarDebug enabled?", foobarDebug.enabled);
will output
debug.enabled('foo:bar')? true
foobarDebug enabled? false
If you create the debugger after calling enable()
it works as expected. I understand that enable()
overrides what was previously enabled, but I would expect that anything that passes the new filters would be enabled.