@jdeighan/coffee-utils 10.0.6 → 10.0.7
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 +1 -1
- package/src/indent_utils.coffee +4 -1
- package/src/indent_utils.js +5 -1
package/package.json
CHANGED
package/src/indent_utils.coffee
CHANGED
@@ -99,7 +99,10 @@ export undented = (input, level=undef, oneIndent="\t") ->
|
|
99
99
|
|
100
100
|
lLines = toArray(input)
|
101
101
|
if (lLines.length == 0)
|
102
|
-
|
102
|
+
if isString(input)
|
103
|
+
return ''
|
104
|
+
else
|
105
|
+
return []
|
103
106
|
|
104
107
|
# --- determine what to remove from beginning of each line
|
105
108
|
if defined(level)
|
package/src/indent_utils.js
CHANGED
@@ -118,7 +118,11 @@ export var undented = function(input, level = undef, oneIndent = "\t") {
|
|
118
118
|
}
|
119
119
|
lLines = toArray(input);
|
120
120
|
if (lLines.length === 0) {
|
121
|
-
|
121
|
+
if (isString(input)) {
|
122
|
+
return '';
|
123
|
+
} else {
|
124
|
+
return [];
|
125
|
+
}
|
122
126
|
}
|
123
127
|
// --- determine what to remove from beginning of each line
|
124
128
|
if (defined(level)) {
|