@trenskow/pged 5.0.19 → 5.0.21

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.
Files changed (2) hide show
  1. package/package.json +2 -2
  2. package/query-builder.js +2 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trenskow/pged",
3
- "version": "5.0.19",
3
+ "version": "5.0.21",
4
4
  "description": "Just a silly little db management and query builder for PostgreSQL.",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -23,7 +23,7 @@
23
23
  },
24
24
  "homepage": "https://github.com/trenskow/pged#readme",
25
25
  "dependencies": {
26
- "@trenskow/async-event-emitter": "^0.1.5",
26
+ "@trenskow/async-event-emitter": "^0.1.6",
27
27
  "@trenskow/caseit": "^1.3.5",
28
28
  "@trenskow/custom-promise": "^0.10.3",
29
29
  "pg": "^8.11.1",
package/query-builder.js CHANGED
@@ -367,7 +367,8 @@ export default class QueryBuilder extends CustomPromise {
367
367
  }
368
368
 
369
369
  if (key.substring(0, 1) == ':') {
370
- return this._buildCondition(key.substring(1), comparer, this._dbCase(condition[key]));
370
+ this._queryParameters.push(this._formatParameter(key, condition[key]));
371
+ return this._buildCondition(key.substring(1), comparer, `$${this._queryParameters.length}`);
371
372
  }
372
373
 
373
374
  let dbKey = key;