pg-promise 11.5.4 → 11.5.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/lib/database.js CHANGED
@@ -1679,5 +1679,5 @@ module.exports = config => {
1679
1679
 
1680
1680
  /**
1681
1681
  * @external Result
1682
- * @see https://node-postgres.com/api/result
1682
+ * @see https://node-postgres.com/apis/result
1683
1683
  */
package/lib/formatting.js CHANGED
@@ -839,7 +839,7 @@ const $as = {
839
839
  * - `obj` - the formatting object, and is the same as `this` context
840
840
  *
841
841
  * - For $[Index Variables] formatting:
842
- * - `index` - element's index (starts with 1) that's outside of the input array
842
+ * - `index` - element's index (starts with 1) that's outside the input array
843
843
  * - `arr` - the formatting/input array, and is the same as `this` context
844
844
  *
845
845
  * You can tell which type of call it is by checking the type of the first parameter.
@@ -884,7 +884,8 @@ const $to = {
884
884
  },
885
885
  number(num) {
886
886
  if (typeof num === 'bigint' || Number.isFinite(num)) {
887
- return num.toString();
887
+ const s = num.toString();
888
+ return num < 0 ? `(${s})` : s;
888
889
  }
889
890
  // Converting NaN/+Infinity/-Infinity according to Postgres documentation:
890
891
  // http://www.postgresql.org/docs/9.6/static/datatype-numeric.html#DATATYPE-FLOAT
package/lib/main.js CHANGED
@@ -415,7 +415,7 @@ module.exports = $main;
415
415
 
416
416
  /**
417
417
  * @external Client
418
- * @see https://node-postgres.com/api/client
418
+ * @see https://node-postgres.com/apis/client
419
419
  */
420
420
 
421
421
  /**
package/lib/query.js CHANGED
@@ -263,9 +263,7 @@ function $query(ctx, query, values, qrm, config) {
263
263
  }
264
264
 
265
265
  // Extends Result to provide iterable for the rows;
266
- //
267
- // To be removed once the following PR is merged amd released:
268
- // https://github.com/brianc/node-postgres/pull/2861
266
+ // See: https://github.com/brianc/node-postgres/pull/2861
269
267
  function makeIterable(r) {
270
268
  r[Symbol.iterator] = function () {
271
269
  return this.rows.values();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pg-promise",
3
- "version": "11.5.4",
3
+ "version": "11.5.5",
4
4
  "description": "PostgreSQL interface for Node.js",
5
5
  "main": "lib/index.js",
6
6
  "typings": "typescript/pg-promise.d.ts",
@@ -50,14 +50,14 @@
50
50
  "@types/node": "20.5.2",
51
51
  "bluebird": "3.7.2",
52
52
  "coveralls": "3.1.1",
53
- "cspell": "7.0.1",
54
- "eslint": "8.47.0",
53
+ "cspell": "8.6.0",
54
+ "eslint": "8.57.0",
55
55
  "istanbul": "0.4.5",
56
56
  "jasmine-node": "3.0.0",
57
57
  "jsdoc": "4.0.2",
58
58
  "JSONStream": "1.3.5",
59
59
  "pg-query-stream": "4.5.3",
60
60
  "tslint": "6.1.3",
61
- "typescript": "5.1.6"
61
+ "typescript": "5.4.3"
62
62
  }
63
63
  }