@asla/yoursql 0.1.0 → 0.1.1
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/dist/mod.js +4 -2
- package/package.json +1 -1
package/dist/mod.js
CHANGED
|
@@ -147,7 +147,7 @@ class SqlValuesCreator {
|
|
|
147
147
|
rows = [];
|
|
148
148
|
j = 0;
|
|
149
149
|
for (; j < keys.length; j++) {
|
|
150
|
-
value = object[keys[j]]
|
|
150
|
+
value = object[keys[j]];
|
|
151
151
|
rows[j] = this.toSqlStr(value);
|
|
152
152
|
}
|
|
153
153
|
str += ",\n(" + rows.join(",") + ")";
|
|
@@ -217,7 +217,9 @@ function getObjectListKeys(objectList, keepUndefinedKey) {
|
|
|
217
217
|
let k;
|
|
218
218
|
for (let j = 0; j < hasKeys.length; j++) {
|
|
219
219
|
k = hasKeys[j];
|
|
220
|
-
if (
|
|
220
|
+
if (typeof k !== "string")
|
|
221
|
+
continue;
|
|
222
|
+
if (!keepUndefinedKey && obj[k] === undefined)
|
|
221
223
|
continue;
|
|
222
224
|
keys.add(k);
|
|
223
225
|
}
|