diff --git a/lib/session/call-session.js b/lib/session/call-session.js index e111535d..d8218e3d 100644 --- a/lib/session/call-session.js +++ b/lib/session/call-session.js @@ -1587,7 +1587,7 @@ class CallSession extends Emitter { const pp = this._pool.promise(); try { this.logger.info({accountSid: this.accountSid}, 'performQueueWebhook: looking up account'); - const [r] = await pp.query(sqlRetrieveQueueEventHook, this.accountSid); + const [r] = await pp.query(sqlRetrieveQueueEventHook, [this.accountSid]); if (0 === r.length) { this.logger.info({accountSid: this.accountSid}, 'performQueueWebhook: no webhook provisioned'); this.queueEventHookRequestor = null; diff --git a/lib/utils/db-utils.js b/lib/utils/db-utils.js index 065aaccc..55e9cb0a 100644 --- a/lib/utils/db-utils.js +++ b/lib/utils/db-utils.js @@ -100,13 +100,13 @@ module.exports = (logger, srf) => { const lookupAccountDetails = async(account_sid) => { - const [r] = await pp.query({sql: sqlAccountDetails, nestTables: true}, account_sid); + const [r] = await pp.query({sql: sqlAccountDetails, nestTables: true}, [account_sid]); if (0 === r.length) throw new Error(`invalid accountSid: ${account_sid}`); - const [r2] = await pp.query(sqlSpeechCredentials, account_sid); + const [r2] = await pp.query(sqlSpeechCredentials, [account_sid]); const speech = r2.map(speechMapper); /* add service provider creds unless we have that vendor at the account level */ - const [r3] = await pp.query(sqlSpeechCredentialsForSP, account_sid); + const [r3] = await pp.query(sqlSpeechCredentialsForSP, [account_sid]); r3.forEach((s) => { if (!speech.find((s2) => s2.vendor === s.vendor)) { speech.push(speechMapper(s)); diff --git a/package-lock.json b/package-lock.json index 97986403..6f6d42ca 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,7 +9,7 @@ "version": "0.8.3", "license": "MIT", "dependencies": { - "@jambonz/db-helpers": "^0.7.10", + "@jambonz/db-helpers": "^0.8.1", "@jambonz/http-health-check": "^0.0.1", "@jambonz/realtimedb-helpers": "^0.7.2", "@jambonz/speech-utils": "^0.0.13", @@ -1595,9 +1595,9 @@ } }, "node_modules/@jambonz/db-helpers": { - "version": "0.7.10", - "resolved": "https://registry.npmjs.org/@jambonz/db-helpers/-/db-helpers-0.7.10.tgz", - "integrity": "sha512-wVZY7je6j01jZNmnzSiuhUz+ufeVEqh8WLi2RPiOJrNk3lFa6eNJJifCCzi5Z71zzIO8jEnDzj54rvbaFgaMtw==", + "version": "0.8.1", + "resolved": "https://registry.npmjs.org/@jambonz/db-helpers/-/db-helpers-0.8.1.tgz", + "integrity": "sha512-pc5TRAYnb89oyD5Ncy9Ik+v/tBqQcNOthbDwaX1OJyGRhPdolgs4YvOTpc0KpSqx7TDjKPS9n5MlqOFWgyDbTA==", "dependencies": { "cidr-matcher": "^2.1.1", "debug": "^4.3.4", @@ -10053,9 +10053,9 @@ "dev": true }, "@jambonz/db-helpers": { - "version": "0.7.10", - "resolved": "https://registry.npmjs.org/@jambonz/db-helpers/-/db-helpers-0.7.10.tgz", - "integrity": "sha512-wVZY7je6j01jZNmnzSiuhUz+ufeVEqh8WLi2RPiOJrNk3lFa6eNJJifCCzi5Z71zzIO8jEnDzj54rvbaFgaMtw==", + "version": "0.8.1", + "resolved": "https://registry.npmjs.org/@jambonz/db-helpers/-/db-helpers-0.8.1.tgz", + "integrity": "sha512-pc5TRAYnb89oyD5Ncy9Ik+v/tBqQcNOthbDwaX1OJyGRhPdolgs4YvOTpc0KpSqx7TDjKPS9n5MlqOFWgyDbTA==", "requires": { "cidr-matcher": "^2.1.1", "debug": "^4.3.4", diff --git a/package.json b/package.json index 8c4dd8bc..f44a1a7a 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,7 @@ "jslint:fix": "eslint app.js tracer.js lib --fix" }, "dependencies": { - "@jambonz/db-helpers": "^0.7.10", + "@jambonz/db-helpers": "^0.8.1", "@jambonz/http-health-check": "^0.0.1", "@jambonz/realtimedb-helpers": "^0.7.2", "@jambonz/speech-utils": "^0.0.13",