`.enabled()` logic incorrectly returns true when namespace contains asterisk
See original GitHub issuedebug.disable('*');
debug.enable('foo');
assert.not(debug.enabled('bar'));
assert.not(debug.enabled('bar*')); // throws; returns true
Has to be solved in two ways:
- More stringent checks on namespaces (as they shouldn’t contain asterisks)
- Remove the check for
ns[ns.length-1]==='*'
, which makes absolutely no sense
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
Some Practice Problems for the C++ Exam and Solutions for ...
If the function is passed an argument that is not positive (i.e., greater than zero), then the function should return the value 0...
Read more >Send related messages in order by using a sequential convoy ...
The scope returns an error message that includes the session ID where the problem happened, and terminates the logic app. Here is the...
Read more >XQuery 3.1: An XML Query Language - W3C
In [XML Path Language (XPath) Version 1.0], the in-scope namespaces of an element node are represented by a collection of namespace nodes ...
Read more >GitHub - ruppysuppy/Daily-Coding-Problem-Solutions
Given the regular expression ". *at" and the string "chat", your function should return true.
Read more >Python Tutorial - Getting Started with Python and Python Basics
As the input() function returns a string, we need to cast it to int . if __name__ == '__main__': (Line 87): When you...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
According to the documentation, this is by design:
naively seems like
if (name === '*') { return true; }
would be less surprising.would be interesting to know if anyone made use of the bar* thing in some way