mm_sqlite 1.4.4 → 1.4.5
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/index.js +2 -2
- package/package.json +1 -1
- package/sql.js +2 -2
package/index.js
CHANGED
|
@@ -209,7 +209,7 @@ SQLite.prototype.run = async function (sql, params = [], timeout = 30000) {
|
|
|
209
209
|
});
|
|
210
210
|
});
|
|
211
211
|
} catch (error) {
|
|
212
|
-
|
|
212
|
+
console.error('SQL执行失败', error);
|
|
213
213
|
this.sql = sql;
|
|
214
214
|
this.error = {
|
|
215
215
|
code: error.errno,
|
|
@@ -275,7 +275,7 @@ SQLite.prototype.exec = async function (sql, params, timeout) {
|
|
|
275
275
|
});
|
|
276
276
|
});
|
|
277
277
|
} catch (error) {
|
|
278
|
-
|
|
278
|
+
console.error('SQL执行失败', error);
|
|
279
279
|
this.sql = sql;
|
|
280
280
|
this.error = {
|
|
281
281
|
code: error.errno,
|
package/package.json
CHANGED
package/sql.js
CHANGED
|
@@ -745,7 +745,7 @@ Sql.prototype.toWhere = function (obj, like) {
|
|
|
745
745
|
}
|
|
746
746
|
}
|
|
747
747
|
}
|
|
748
|
-
return where.replace(
|
|
748
|
+
return where.replace(/^ and /, '');
|
|
749
749
|
};
|
|
750
750
|
|
|
751
751
|
/**
|
|
@@ -770,7 +770,7 @@ Sql.prototype.toSet = function (obj) {
|
|
|
770
770
|
set += ',' + escapeId(k) + ' = ' + val;
|
|
771
771
|
}
|
|
772
772
|
}
|
|
773
|
-
return set.replace(
|
|
773
|
+
return set.replace(/^,/, '');
|
|
774
774
|
};
|
|
775
775
|
|
|
776
776
|
/**
|