@jdeighan/coffee-utils 6.0.8 → 6.0.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@jdeighan/coffee-utils",
3
3
  "type": "module",
4
- "version": "6.0.8",
4
+ "version": "6.0.9",
5
5
  "description": "A set of utility functions for CoffeeScript",
6
6
  "main": "coffee_utils.js",
7
7
  "exports": {
@@ -38,21 +38,20 @@ export setDEBUGDEBUG = (flag=true) ->
38
38
 
39
39
  # ---------------------------------------------------------------------------
40
40
 
41
- export resetDebugging = (funcDoDebug=undef, funcDoLog=undef) ->
41
+ resetDebugging = () ->
42
42
 
43
43
  debugging = false
44
44
  debugLevel = 0
45
45
  stack.reset()
46
46
  shouldDebugFunc = (func) -> debugging
47
47
  shouldLogString = (str) -> debugging
48
- if funcDoDebug
49
- setDebugging funcDoDebug, funcDoLog
50
48
  return
51
49
 
52
50
  # ---------------------------------------------------------------------------
53
51
 
54
52
  export setDebugging = (funcDoDebug=undef, funcDoLog=undef) ->
55
53
 
54
+ resetDebugging()
56
55
  if isBoolean(funcDoDebug)
57
56
  if DEBUGDEBUG
58
57
  console.log "setDebugging #{funcDoDebug}"
@@ -1,6 +1,6 @@
1
1
  // Generated by CoffeeScript 2.6.1
2
2
  // debug_utils.coffee
3
- var DEBUGDEBUG, curEnv, debugLevel, reMethod, setEnv, shouldDebugFunc, shouldLogString, stack;
3
+ var DEBUGDEBUG, curEnv, debugLevel, reMethod, resetDebugging, setEnv, shouldDebugFunc, shouldLogString, stack;
4
4
 
5
5
  import {
6
6
  assert,
@@ -75,7 +75,7 @@ export var setDEBUGDEBUG = function(flag = true) {
75
75
  };
76
76
 
77
77
  // ---------------------------------------------------------------------------
78
- export var resetDebugging = function(funcDoDebug = undef, funcDoLog = undef) {
78
+ resetDebugging = function() {
79
79
  debugging = false;
80
80
  debugLevel = 0;
81
81
  stack.reset();
@@ -85,14 +85,12 @@ export var resetDebugging = function(funcDoDebug = undef, funcDoLog = undef) {
85
85
  shouldLogString = function(str) {
86
86
  return debugging;
87
87
  };
88
- if (funcDoDebug) {
89
- setDebugging(funcDoDebug, funcDoLog);
90
- }
91
88
  };
92
89
 
93
90
  // ---------------------------------------------------------------------------
94
91
  export var setDebugging = function(funcDoDebug = undef, funcDoLog = undef) {
95
92
  var lFuncNames;
93
+ resetDebugging();
96
94
  if (isBoolean(funcDoDebug)) {
97
95
  if (DEBUGDEBUG) {
98
96
  console.log(`setDebugging ${funcDoDebug}`);