@naturalcycles/db-lib 8.43.2 → 8.43.3

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.
@@ -10,7 +10,7 @@ import { CommonDaoCfg, CommonDaoCreateOptions, CommonDaoOptions, CommonDaoSaveOp
10
10
  * BM = Backend model (optimized for API access)
11
11
  * TM = Transport model (optimized to be sent over the wire)
12
12
  */
13
- export declare class CommonDao<BM extends Partial<ObjectWithId<ID>>, DBM extends ObjectWithId<ID> = Saved<BM>, TM extends AnyObject = BM, ID extends string | number = string> {
13
+ export declare class CommonDao<BM extends Partial<ObjectWithId<ID>>, DBM extends ObjectWithId<ID> = Saved<BM>, TM extends AnyObject = BM, ID extends string | number = NonNullable<BM['id']>> {
14
14
  cfg: CommonDaoCfg<BM, DBM, TM, ID>;
15
15
  constructor(cfg: CommonDaoCfg<BM, DBM, TM, ID>);
16
16
  create(part?: Partial<BM>, opt?: CommonDaoOptions): Saved<BM>;
package/package.json CHANGED
@@ -41,7 +41,7 @@
41
41
  "engines": {
42
42
  "node": ">=14.15"
43
43
  },
44
- "version": "8.43.2",
44
+ "version": "8.43.3",
45
45
  "description": "Lowest Common Denominator API to supported Databases",
46
46
  "keywords": [
47
47
  "db",
@@ -71,7 +71,7 @@ export class CommonDao<
71
71
  BM extends Partial<ObjectWithId<ID>>,
72
72
  DBM extends ObjectWithId<ID> = Saved<BM>,
73
73
  TM extends AnyObject = BM,
74
- ID extends string | number = string,
74
+ ID extends string | number = NonNullable<BM['id']>,
75
75
  > {
76
76
  constructor(public cfg: CommonDaoCfg<BM, DBM, TM, ID>) {
77
77
  this.cfg = {