Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Changes as per PR comments - future extension support
  • Loading branch information
kileha3 committed Aug 11, 2021
commit b30b00951ea4f97e76c1c3229b71feda13e16b77
3 changes: 2 additions & 1 deletion src/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -410,6 +410,7 @@ Module["onRuntimeInitialized"] = function onRuntimeInitialized() {
while (stmt.step()) console.log(stmt.get(null, {useBigInt: true}));
*/
Statement.prototype["get"] = function get(params, config) {
config = config || {};
if (params != null && this["bind"](params)) {
this["step"]();
}
Expand All @@ -418,7 +419,7 @@ Module["onRuntimeInitialized"] = function onRuntimeInitialized() {
for (var field = 0; field < ref; field += 1) {
switch (sqlite3_column_type(this.stmt, field)) {
case SQLITE_INTEGER:
var getfunc = config && config.useBigInt
var getfunc = config["useBigInt"]
? this.getBigInt(field)
: this.getNumber(field);
results1.push(getfunc);
Expand Down