@naturalcycles/db-lib 10.35.0 → 10.35.1

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/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@naturalcycles/db-lib",
3
3
  "type": "module",
4
- "version": "10.35.0",
4
+ "version": "10.35.1",
5
5
  "dependencies": {
6
6
  "@naturalcycles/js-lib": "^15",
7
7
  "@naturalcycles/nodejs-lib": "^15"
8
8
  },
9
9
  "devDependencies": {
10
- "@naturalcycles/dev-lib": "18.4.2"
10
+ "@naturalcycles/dev-lib": "20.12.10"
11
11
  },
12
12
  "files": [
13
13
  "dist",
@@ -64,8 +64,7 @@ export interface CacheDBOptions extends CommonDBOptions {
64
64
  }
65
65
 
66
66
  export interface CacheDBSaveOptions<ROW extends ObjectWithId>
67
- extends CacheDBOptions,
68
- CommonDBSaveOptions<ROW> {}
67
+ extends CacheDBOptions, CommonDBSaveOptions<ROW> {}
69
68
 
70
69
  export interface CacheDBStreamOptions extends CacheDBOptions, CommonDBStreamOptions {}
71
70
 
@@ -282,8 +282,10 @@ export interface CommonDaoReadOptions extends CommonDaoOptions {
282
282
  readAt?: UnixTimestamp
283
283
  }
284
284
 
285
- export interface CommonDaoSaveOptions<BM extends BaseDBEntity, DBM extends BaseDBEntity>
286
- extends CommonDaoSaveBatchOptions<DBM> {
285
+ export interface CommonDaoSaveOptions<
286
+ BM extends BaseDBEntity,
287
+ DBM extends BaseDBEntity,
288
+ > extends CommonDaoSaveBatchOptions<DBM> {
287
289
  /**
288
290
  * If provided - a check will be made.
289
291
  * If the object for saving equals to the object passed to `skipIfEquals` - save operation will be skipped.
@@ -295,8 +297,9 @@ export interface CommonDaoSaveOptions<BM extends BaseDBEntity, DBM extends BaseD
295
297
  skipIfEquals?: BM
296
298
  }
297
299
 
298
- export interface CommonDaoPatchByIdOptions<DBM extends BaseDBEntity>
299
- extends CommonDaoSaveBatchOptions<DBM> {
300
+ export interface CommonDaoPatchByIdOptions<
301
+ DBM extends BaseDBEntity,
302
+ > extends CommonDaoSaveBatchOptions<DBM> {
300
303
  /**
301
304
  * Defaults to false.
302
305
  * With false, if the row doesn't exist - it will throw an error.
@@ -307,8 +310,9 @@ export interface CommonDaoPatchByIdOptions<DBM extends BaseDBEntity>
307
310
  createIfMissing?: boolean
308
311
  }
309
312
 
310
- export interface CommonDaoPatchOptions<DBM extends BaseDBEntity>
311
- extends CommonDaoSaveBatchOptions<DBM> {
313
+ export interface CommonDaoPatchOptions<
314
+ DBM extends BaseDBEntity,
315
+ > extends CommonDaoSaveBatchOptions<DBM> {
312
316
  /**
313
317
  * If true - patch will skip loading from DB, and will just optimistically patch passed object.
314
318
  *
@@ -321,8 +325,7 @@ export interface CommonDaoPatchOptions<DBM extends BaseDBEntity>
321
325
  * All properties default to undefined.
322
326
  */
323
327
  export interface CommonDaoSaveBatchOptions<DBM extends BaseDBEntity>
324
- extends CommonDaoOptions,
325
- CommonDBSaveOptions<DBM> {
328
+ extends CommonDaoOptions, CommonDBSaveOptions<DBM> {
326
329
  /**
327
330
  * @default false
328
331
  *
@@ -335,16 +338,15 @@ export interface CommonDaoSaveBatchOptions<DBM extends BaseDBEntity>
335
338
  // ensureUniqueId?: boolean // feature is currently disabled
336
339
  }
337
340
 
338
- export interface CommonDaoStreamDeleteOptions<DBM extends BaseDBEntity>
339
- extends CommonDaoStreamOptions<DBM> {}
341
+ export interface CommonDaoStreamDeleteOptions<
342
+ DBM extends BaseDBEntity,
343
+ > extends CommonDaoStreamOptions<DBM> {}
340
344
 
341
345
  export interface CommonDaoStreamSaveOptions<DBM extends BaseDBEntity>
342
- extends CommonDaoSaveBatchOptions<DBM>,
343
- CommonDaoStreamOptions<DBM> {}
346
+ extends CommonDaoSaveBatchOptions<DBM>, CommonDaoStreamOptions<DBM> {}
344
347
 
345
348
  export interface CommonDaoStreamOptions<IN>
346
- extends CommonDaoReadOptions,
347
- TransformLogProgressOptions<IN> {
349
+ extends CommonDaoReadOptions, TransformLogProgressOptions<IN> {
348
350
  /**
349
351
  * @default true (for streams)
350
352
  */