@budibase/backend-core 2.23.0 → 2.23.2
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/index.js +7 -4
- package/dist/index.js.map +2 -2
- package/dist/index.js.meta.json +1 -1
- package/dist/package.json +4 -4
- package/dist/plugins.js.meta.json +1 -1
- package/dist/src/db/couch/DatabaseImpl.d.ts +2 -2
- package/dist/src/db/couch/DatabaseImpl.js +5 -2
- package/dist/src/db/couch/DatabaseImpl.js.map +1 -1
- package/dist/src/db/instrumentation.d.ts +2 -2
- package/dist/src/db/instrumentation.js +2 -2
- package/dist/src/db/instrumentation.js.map +1 -1
- package/package.json +4 -4
- package/src/db/couch/DatabaseImpl.ts +9 -2
- package/src/db/instrumentation.ts +6 -2
package/dist/index.js
CHANGED
|
@@ -55702,10 +55702,10 @@ var DDInstrumentedDatabase = class {
|
|
|
55702
55702
|
return this.db.getIndexes(...args);
|
|
55703
55703
|
});
|
|
55704
55704
|
}
|
|
55705
|
-
sql(sql) {
|
|
55705
|
+
sql(sql, parameters) {
|
|
55706
55706
|
return import_dd_trace.default.trace("db.sql", (span) => {
|
|
55707
55707
|
span?.addTags({ db_name: this.name });
|
|
55708
|
-
return this.db.sql(sql);
|
|
55708
|
+
return this.db.sql(sql, parameters);
|
|
55709
55709
|
});
|
|
55710
55710
|
}
|
|
55711
55711
|
};
|
|
@@ -55891,14 +55891,17 @@ var DatabaseImpl = class _DatabaseImpl {
|
|
|
55891
55891
|
return () => db.list(params2);
|
|
55892
55892
|
});
|
|
55893
55893
|
}
|
|
55894
|
-
async sql(sql) {
|
|
55894
|
+
async sql(sql, parameters) {
|
|
55895
55895
|
const dbName = this.name;
|
|
55896
55896
|
const url = `/${dbName}/${SQLITE_DESIGN_DOC_ID}`;
|
|
55897
55897
|
const response = await directCouchUrlCall({
|
|
55898
55898
|
url: `${this.couchInfo.sqlUrl}/${url}`,
|
|
55899
55899
|
method: "POST",
|
|
55900
55900
|
cookie: this.couchInfo.cookie,
|
|
55901
|
-
body:
|
|
55901
|
+
body: {
|
|
55902
|
+
query: sql,
|
|
55903
|
+
args: parameters
|
|
55904
|
+
}
|
|
55902
55905
|
});
|
|
55903
55906
|
if (response.status > 300) {
|
|
55904
55907
|
throw new Error(await response.text());
|